You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I found using pytest with parameter with --durations-path option will change pytest rootdir, so the nodeid of all tests cannot be found in the test_durations file.
For example
It is hard to say it is a bug on pytest-split side. The pytest algorithm to determine rootdir is also weird. We can easily avoid this issue using --rootdir option, or move test_durations file to project rootdir before running pytest. But just want to ask is there a better design? There is no error so I did not find this issue for a long time.
The text was updated successfully, but these errors were encountered:
Hi,
I found using
pytest
with parameter with--durations-path
option will change pytest rootdir, so the nodeid of all tests cannot be found in the test_durations file.For example
The rootdir is my home folder. So basically the nodeids stored in test_duration are not used. This is a pytest's documentation https://docs.pytest.org/en/6.2.x/customize.html#initialization-determining-rootdir-and-configfile
It is hard to say it is a bug on pytest-split side. The
pytest
algorithm to determine rootdir is also weird. We can easily avoid this issue using--rootdir
option, or movetest_durations
file to project rootdir before running pytest. But just want to ask is there a better design? There is no error so I did not find this issue for a long time.The text was updated successfully, but these errors were encountered: