diff --git a/.stestr.conf b/.stestr.conf new file mode 100644 index 0000000..bd0b4c9 --- /dev/null +++ b/.stestr.conf @@ -0,0 +1,3 @@ +[DEFAULT] +test_path=./venus/tests +top_dir=./ diff --git a/tox.ini b/tox.ini index 82a0eff..7da272b 100644 --- a/tox.ini +++ b/tox.ini @@ -8,13 +8,17 @@ basepython = python3 # Note the hash seed is set to 0 until venus can be tested with a # random hash seed successfully. setenv = VIRTUAL_ENV={envdir} - PYTHONHASHSEED=0 + OS_TEST_PATH=venus/tests/unit usedevelop = True install_command = pip install {opts} {packages} deps = - -r{toxinidir}/requirements.txt - -r{toxinidir}/test-requirements.txt + -c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master} + -r{toxinidir}/requirements.txt + -r{toxinidir}/test-requirements.txt + +commands = rm -f .testrepository/times.dbm + stestr run --slowest {posargs} [testenv:releasenotes] deps = -r{toxinidir}/doc/requirements.txt @@ -26,6 +30,20 @@ commands = # Check that .po and .pot files are valid: doc8 --ignore D001 doc/source/ CONTRIBUTING.rst HACKING.rst README.rst +[testenv:venv] +commands = {posargs} + +[testenv:cover] +setenv = + PYTHON=coverage run --source cyborg --parallel-mode +commands = + coverage erase + stestr run {posargs} + coverage combine + coverage html -d cover + coverage xml -o cover/coverage.xml + coverage report + [doc8] ignore-path = .venv,.git,.tox,*venus/locale*,*lib/python*,*venus.egg*,api-ref/build,doc/build,doc/source/contributor/api