Delete python bytecode before every test run

Bring over the cleaning line from run_tests.sh for the pyc files to
all the tox runs.

This should eliminate the need to clean -x -i to kill pyc files in
your local directory to get tests to pass.

Change-Id: I3e1c53a26440aaff5dd92cd5381d71a1d411ebe8
Closes-Bug: #1368661
This commit is contained in:
Haiwei Xu 2015-12-02 10:03:08 +09:00
parent 752dc6708a
commit 51b0b28a05
1 changed files with 4 additions and 1 deletions

View File

@ -6,10 +6,13 @@ skipsdist = True
setenv = VIRTUAL_ENV={envdir}
usedevelop = True
install_command = pip install -U {opts} {packages} --pre
whitelist_externals = find
deps = -r{toxinidir}/requirements.txt
-r{toxinidir}/test-requirements.txt
MySQL-python
commands = nosetests
commands =
find . -type f -name "*.pyc" -delete
nosetests
[testenv:py27-postgres]
deps = -r{toxinidir}/requirements.txt