Delete python bytecode before every test run

Because python creates pyc files during tox runs, certain
changes in the tree, like deletes of files, or switching
branches, can create spurious errors.

Change-Id: I9b0e7afeeb934d24c9847573cd7582709e990c9e
Closes-Bug: #1368661
This commit is contained in:
shu-mutou 2015-12-02 12:36:56 +09:00
parent 35066b234d
commit debd086b2a
1 changed files with 3 additions and 1 deletions

View File

@ -9,7 +9,9 @@ usedevelop = True
install_command = pip install -U {opts} {packages}
deps = -r{toxinidir}/requirements.txt
-r{toxinidir}/test-requirements.txt
commands = python setup.py testr --slowest --testr-args='{posargs}'
commands = find . -type f -name "*.pyc" -delete
python setup.py testr --slowest --testr-args='{posargs}'
whitelist_externals = find
[testenv:pypy]
deps = setuptools<3.2