- Notifications
You must be signed in to change notification settings - Fork 242
Description
I am fairly new to this project. I very recently migrated a software project test-suite from nosetest to pytest, mainly because of the Xdist benefits I had heard of.
The problem is that my Tests are depending on a big fixture setup (table creation + heavy loading of data) that I would like to share across all my tests.
The current Xdist behaviour is as follow:
- Collect test
- Split tests amongst the user-defined number of processes
- Launch a pytest session for each worker
Obviously, if each test depend on a heavy fixture, then multiplying the number of creation per number of worker is not going to help.
Additionally, it simply breaks the expected pytest behaviour for 'session' scoped fixtures.
I think this should be fairly simple to address this problem although I didn't take a really deep look into it. If you need help to solve this problem, I am more than willing to contribute if you feel this suggestion for improvement is relevant.
Greetings.