Skip to content

Commit 0784df8

Browse files
committed
Change the check_leftover_jobs fixture to run at session level
Given there's no known job leakage problems at the moment, it's fine to have the `check_leftover_jobs` fixture run only once per test run rather than once per test case. If a leftover job does indeed become a problem, it's easy to change the scope back temporarily to help debug.
1 parent f4d1361 commit 0784df8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tests/conftest.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ def simple_args(request: pytest.FixtureRequest):
8383
return SimpleArgs(test_name=request.node.name)
8484

8585

86-
@pytest.fixture(autouse=True)
86+
@pytest.fixture(autouse=True, scope="session")
8787
def check_leftover_jobs(engine) -> Iterator[None]:
8888
"""
8989
Autorunning fixture that checks for leftover jobs after each test case. I

0 commit comments

Comments
 (0)