pytest-dev / pytest-dev/pytest-factoryboy
How can I pass function-scope fixtures (e.g. db sessions) to each Factory in combination with pytest-asyncio?
Open
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 400
- Forks
- 44
- Avg merge
- 6h 34m
- Merged PRs (30d)
- 1
Description
I want each factory instance to have access to pytest-function scoped (global) fixtures such as db session but have no means to inject hooks to pytest fixtures at each factory's instantiation.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
No file or test is named. Start by reviewing the pytest fixture lifecycle and the pytest-asyncio integration around factory instantiation; clarify how function-scoped fixtures should reach each Factory. Done should define and verify a supported injection mechanism.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- testing
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100