outer fixture not run when running nested test #8917
Unanswered
stefanseefeld
asked this question in
Q&A
Replies: 1 comment 4 replies
-
it should work, if it does in fact not, thats a bug we need to fix do you by chance have a minimal reproducer? |
Beta Was this translation helpful? Give feedback.
4 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello,
I have a test suite with a couple of subdirectories, each of which adds sub-directory specific fixtures, in addition to the toplevel
conftest.py
providing generic fixtures used by all tests.How can I invoke a specific test from a sub-directory, while still using fixtures defined in "outer"
conftest.py
files ?Assume a structure like
With the above, if I run
pytest tests/b/test_3.py
, fixtures from `tests/conftest.py aren't seen, so I get an internal error if those tests require such fixtures. What is the expected way to run individual tests with the above testsuite structure ?Beta Was this translation helpful? Give feedback.
All reactions