We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The following example causes non-deterministic failures when trying to run tests in parallel:
import pytest @pytest.fixture(scope="module", params=['A', 'B']) def fa(request): return request.param @pytest.fixture(scope="module", params=['A', 'B']) def fb(request): return request.param def test_it(fa, fb): pass
$ pytest test.py -n 4 ================================== test session starts ================================== platform darwin -- Python 3.6.2, pytest-3.1.3, py-1.4.34, pluggy-0.4.0 rootdir: /Users/tom/tmp, inifile: plugins: cov-2.3.1, mpl-0.8, xdist-1.18.2 gw0 [4] / gw1 [4] / gw2 [4] / gw3 [4] scheduling tests via LoadScheduling collecting 0 items / 1 errors ======================================== ERRORS ========================================= _________________________________ ERROR collecting gw3 __________________________________ Different tests were collected between gw1 and gw3. The difference is: --- gw1 +++ gw3 @@ -1,4 +1,4 @@ test.py::test_it[A-A] +test.py::test_it[A-B] +test.py::test_it[B-B] test.py::test_it[B-A] -test.py::test_it[B-B] -test.py::test_it[A-B] ================================ 1 error in 1.47 seconds ================================
Note that you need to try multiple times for the failure to appear in some cases. This is using Python 3.6.2 and pytest 3.1.3.
The text was updated successfully, but these errors were encountered:
Can you try with pytest-3.2.0? I believe this has been fixed by pytest-dev/pytest#920
pytest-3.2.0
Sorry, something went wrong.
It does seem to be fixed, thanks!
No branches or pull requests
The following example causes non-deterministic failures when trying to run tests in parallel:
Note that you need to try multiple times for the failure to appear in some cases. This is using Python 3.6.2 and pytest 3.1.3.
The text was updated successfully, but these errors were encountered: