move 'check-memory' from Makefile into tox.ini

So use 'tox -e check-memory' instead of 'make check-memory'. The tox
version will create a virtualenv and install tahoe for you before
running the tests, removing one use of the 'tahoe @FILENAME' hack (which
was used to run a python file with a PYTHONPATH set to import tahoe's
dependencies).
This commit is contained in:
Brian Warner 2016-03-08 21:17:51 -08:00
parent e052134309
commit 24ed8431b2
3 changed files with 14 additions and 16 deletions

1
.gitignore vendored
View File

@ -23,6 +23,7 @@ zope.interface-*.egg
.pc
/_trial_temp*
/_test_memory/
/tmp*
/*.patch
/dist/

View File

@ -166,22 +166,6 @@ count-lines:
@echo -n "XXX: "
@grep XXX `find src -name '*.py' |grep -v /build/` | wc -l
.PHONY: check-memory
check-memory: .built
rm -rf _test_memory
$(TAHOE) @src/allmydata/test/check_memory.py upload
$(TAHOE) @src/allmydata/test/check_memory.py upload-self
$(TAHOE) @src/allmydata/test/check_memory.py upload-POST
$(TAHOE) @src/allmydata/test/check_memory.py download
$(TAHOE) @src/allmydata/test/check_memory.py download-GET
$(TAHOE) @src/allmydata/test/check_memory.py download-GET-slow
$(TAHOE) @src/allmydata/test/check_memory.py receive
.PHONY: check-memory-once
check-memory-once: .built
rm -rf _test_memory
$(TAHOE) @src/allmydata/test/check_memory.py $(MODE)
# The check-speed target uses a pre-established client node to run a canned
# set of performance tests against a test network that is also
# pre-established (probably on a remote machine). Provide it with the path to

13
tox.ini
View File

@ -28,3 +28,16 @@ commands =
python setup.py update_version
python setup.py make_executable
trial --rterrors allmydata
[testenv:checkmemory]
commands =
python setup.py update_version
python setup.py make_executable
rm -rf _test_memory
python src/allmydata/test/check_memory.py upload
python src/allmydata/test/check_memory.py upload-self
python src/allmydata/test/check_memory.py upload-POST
python src/allmydata/test/check_memory.py download
python src/allmydata/test/check_memory.py download-GET
python src/allmydata/test/check_memory.py download-GET-slow
python src/allmydata/test/check_memory.py receive