pytest-dev / pytest-dev/pytest-django
Fixtures that save to database silently pass if they don't use the "db" fixture
Open
Nobody has claimed this yet.
bug
- Dominant language
- Python
- Stars
- 1.5k
- Forks
- 367
- PR merge metrics
- No merged PRs in 30d
Description
This is very annoying as you don't have clear indication of why your fixture doesn't work. Any database changing actions done in a fixture that doesn't depend on db/transactional_db should raise clear errors indicating the problem.
Contributor guide
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
Start by locating how pytest-django handles the db and transactional_db fixtures and database access from fixtures. Reproduce a database-changing fixture without either dependency, then identify the existing error-reporting path. Done means such actions raise a clear error explaining the missing fixture dependency.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- django, python
- Domain
- databases, testing
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100