I am using Python 3.7.4, pytest 6.2.5, tox 3.24.4. Is it an expected behavior that pytest failure will cause tox command (wrap around the pytest) exited with code 1? Appreciate your insights.
Command as follows indicated in Jenkins console log:
foobar run-test: commands[0] | pytest test_foobar.py
Error below:
InvocationError for command /path/.tox/foobar/bin/pytest test_foobar.py (exited with code 1)
Here is the tox.ini file.
[tox]
envlist = foobar,xxx
skipsdist = true
[testenv]
basepython = python3.7
passenv = *
[testenv:foobar]
deps =
-r requirements.txt
commands =
pytest {posargs}
[testenv:xxx]
envdir = {toxworkdir}/foobar
deps =
{[testenv:foobar]deps}
commands =
<something> {posargs}