mercredi 11 mars 2020

Session-scoped fixture with pytest-xdist: setup committed once before test suite

I run 10 tests with pytest-xdist. I also have a session-scoped fixture. The session-scoped fixture runs 10 time as would a function-scoped fixture. I would like to create an entity once for all tests (from get_entity by first running test) and get the instance for all other 9 tests. What is the best practices for that?

Aucun commentaire:

Enregistrer un commentaire