Signed-off-by: Daira Hopwood <daira@jacaranda.org>
.PHONY: quicktest
quicktest: make-version
- $(TAHOE) debug trial $(TRIALARGS) $(TEST)
+ @PYTHONWARNINGS=default::DeprecationWarning $(TAHOE) debug trial $(TRIALARGS) $(TEST)
# "make tmpfstest" may be a faster way of running tests on Linux. It works best when you have
# at least 330 MiB of free physical memory (to run the whole test suite). Since it uses sudo
.PHONY: _tmpfstest
_tmpfstest: make-version
sudo mount -t tmpfs -o size=400m tmpfs '$(TMPDIR)'
- -$(TAHOE) debug trial --rterrors '--temp-directory=$(TMPDIR)/_trial_temp' $(TRIALARGS) $(TEST)
+ @PYTHONWARNINGS=default::DeprecationWarning -$(TAHOE) debug trial --rterrors '--temp-directory=$(TMPDIR)/_trial_temp' $(TRIALARGS) $(TEST)
sudo umount '$(TMPDIR)'
rmdir '$(TMPDIR)'
.PHONY: test-coverage
test-coverage: build
rm -f .coverage
- $(TAHOE) '@$(COVERAGE)' run $(COVERAGEARGS) @tahoe debug trial $(TRIALARGS) $(TEST)
+ @PYTHONWARNINGS=default::DeprecationWarning $(TAHOE) '@$(COVERAGE)' run $(COVERAGEARGS) @tahoe debug trial $(TRIALARGS) $(TEST)
.PHONY: coverage-output
coverage-output:
pass
def run(self):
+ # enable deprecation warnings (once per line) even on Python 2.7
+ new_env = os.environ.copy()
+ new_env["PYTHONWARNINGS"] = "default::DeprecationWarning"
+
args = [sys.executable, os.path.join('bin', 'tahoe')]
if self.coverage:
args.append('--reporter=' + self.reporter)
if self.suite:
args.append(self.suite)
- rc = subprocess.call(args)
+ rc = subprocess.call(args, env=new_env)
sys.exit(rc)