Stop using pytest-randomly
in tests
#112
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This removes the
pytest-randomly
Pytest plugin, as it doesn't play nice withpytest-xdist
.pytest-randomly
(among other things) sets the random seed in the beginning of the tests to the current datetime.pytest-xdist
runs the tests in parallel in multiple runners. When you use these two together, it happens that all of the runners have the same random seed, so if you e.g. generate random resource names, all runners will generate the same ones, leading to conflicts.The other feature of
pytest-randomly
, running the tests in random order to ensure that the tests are not passing just because of some side effects caused by running in a specific order, does not work withpytest-xdist
at all, so there are zero benefits of usingpytest-randomly
at all.