silly-queen-7197
08/18/2025, 10:49 PM__defaults__(
{
"python_test": {
"dependencies.add": ["path/to/common/fixtures.py"],
},
}
)
Using python_test_utils is great for a conftest but what about a conftest for the entire monorepo? (our monorepo is a collection of directories like {top-level-project}/src and {top-level-project}/tests)silly-queen-7197
08/18/2025, 11:53 PMsilly-queen-7197
08/19/2025, 12:08 AMsilly-queen-7197
08/19/2025, 12:10 AMelegant-florist-94385
08/19/2025, 10:41 AMpython_test_utils targets describing your conftest.py files, all conftest.py files in the same directory or any parent directory of a python_test target should be recognized as dependencies automatically.
In other words, there should be no need for what you are trying to do. Can you share what your directory structure and BUILD files look like (or a reduced example)?silly-queen-7197
08/19/2025, 3:12 PMconftest adjacent to the tests that use them. I was able to also get it to work by having a conftest in my root directory with a “pytest_plugin = …“. I think between fighting weird syntax of __defaults__ and pytest fixture magic I didn’t think clearly enough about what I was actually trying to achieve.elegant-florist-94385
08/19/2025, 3:13 PM