stubBGMode forces spawner.IsBackground() true for the test.
(t *testing.T)
| 77 | |
| 78 | // stubBGMode forces spawner.IsBackground() true for the test. |
| 79 | func stubBGMode(t *testing.T) { |
| 80 | t.Helper() |
| 81 | tru := true |
| 82 | old := spawner.BackgroundOverride |
| 83 | spawner.BackgroundOverride = &tru |
| 84 | t.Cleanup(func() { spawner.BackgroundOverride = old }) |
| 85 | } |
| 86 | |
| 87 | type bgCalls struct { |
| 88 | spawn, resume, agents int |
no outgoing calls
no test coverage detected