Dedicated repository for exhibiting the problem and with detailed description see https://github.com/vlcinsky/pytest_generate_tests-conflicts
From "summary" in repository README.md
As shown in 003_conftest_fixt1, when pytest_generate_tests provided a value for test case
parameter and at the same time conftest.py provides a fixture with the same name, it wrongly
attempts to define a test case call also with the value from conftest.py fixture.
Expected behaviour is, that once a test function gets value for a parameter from
pytest_generate_tests, then further collection of values for this parameter shall stop.
Alternatively it shall resolve the duplication by giving the pytest_generate_tests parameter value
preference.
As shown in 005_conftest_fixt2, when pytest_generate_tests provides a value for a test case
parameter and at the same time in conftest.py there exist a fixture, which is dependent on another
one, it results in collecting the same test call (having the same combination of parameter values)
multiple times, this time it goes around Duplicate values by generating new test id using
parameter value from conftest.py fixture.
Expected behaviour is the same as described in "Duplicate values" above.
@vlcinsky thanks a lot for all the effort you put into creating a repository and documenting each case, we really appreciate it.
@nicoddemus This is my contribution to my beloved testing framework. Good quality issue description is rather easy comparing to reading pytest internals what I gave up being happy, others take care of it.
Most helpful comment
@nicoddemus This is my contribution to my beloved testing framework. Good quality issue description is rather easy comparing to reading pytest internals what I gave up being happy, others take care of it.