Remove *.pyc files before running tox tests

Modified tox.ini to remove any .pyc file before running tests.
Also, now it removes all the __pycache__ folders which was also
in the bug report.

Change-Id: I2f60751b155f8098b746339c12406b934bcdbcf9
Closes-Bug: #1525852
This commit is contained in:
Gábor Antal 2015-12-17 11:58:16 +01:00
parent d3160bf007
commit 35a5ba1cd0

View File

@ -5,12 +5,16 @@ skipsdist = True
[testenv]
usedevelop = True
whitelist_externals = find
install_command = pip install -U {opts} {packages}
setenv =
VIRTUAL_ENV={envdir}
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
find . -type d -name "__pycache__" -delete
python setup.py testr --slowest --testr-args='{posargs}'
[testenv:pep8]
commands = flake8