Closed orsinium closed 9 months ago
No, I don't think that this is in scope for this plugin. There is a defined order of fixtures, and to achieve the result you want you just have to reorder the fixtures in the test:
def test_ex1(fixt3, fixt2):
print(">>> test1")
At least, that is what the pytest implementation does - the documentation actually gives no guarantees here... Anyway, even if it would make sense, this would be out of scope of this plugin. A separate plugin might make sense here.
And after a quick search, there seems to already exist a plugin that does exactly that.
Thank you! I'll try the plugin, it seems to work, at least in simple cases.
The pytest-order doesn't order fixtures. Would this feature be in the scope of the plugin?
To reproduce:
Running:
Output:
Expected: