Commit 8ca8906
committed
🧪 Guard shared manager runner in tests (#7279)
Prevent tests from closing the shared manager runner directly.
The original CI failure was caused by tests creating a custom
runner that could still share the event loop of the cached global
manager runner. When the custom runner was closed in teardown, it
closed that shared loop as well. A later test then reused the
cached manager runner and failed because it still pointed to the
closed loop.
This commit makes that contract explicit in the test fixtures.
Tests are no longer allowed to close the global manager runner.
Instead, tests that need shutdown semantics must use isolated
runner fixtures with their own event loop. For tests that need to
exercise manager-based shutdown, an isolated runner can be
temporarily installed as the manager runner.
The CalcJob caching test is also adjusted to clear the plugin
version cache directly instead of resetting the global runner,
which would now violate the stronger isolation policy.1 parent 3d44c1d commit 8ca8906
1 file changed
Lines changed: 7 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
18 | | - | |
19 | 18 | | |
20 | 19 | | |
21 | 20 | | |
22 | 21 | | |
23 | 22 | | |
24 | | - | |
25 | | - | |
26 | | - | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
27 | 30 | | |
28 | 31 | | |
29 | 32 | | |
| |||
0 commit comments