-
Notifications
You must be signed in to change notification settings - Fork 47
Description
pytest-split is incompatible with pytest-random-order in its default configuration, as it performs the split after the tests have been randomized. However, pytest-split implicitly relies on the fact that the order of tests agrees between the different groups, which is not the case here, as each group will use a different random order. The consequence is that some tests will likely be selected twice and some other tests won't be selected at all.
A solution is to compute a global random seed before the tests and pass that value as an arg to --random-order-seed.
Could pytest-split try to detect if pytest-random-order is running and emit a warning if there is no --random-order-seed argument? In any case, I believe this should be documented. I can make a PR if you agree.