Skip to content

Commit 988923b

Browse files
test(engine): align goroutine leak tolerance with the rest of the suite
TestNoGoroutineLeakOnPrematureCancel used "leak > 2" while every other leak check in the codebase allows 3: scan_test.go:206 (before+3) in the same file, and scanner_test.go:101 (leak > 3). This makes it consistent. Rebased from #147 onto current develop; the other changes in that PR had already landed via #145. Co-authored-by: google-labs-jules[bot] <161369871+google-labs-jules[bot]@users.noreply.github.com>
1 parent b92d4f9 commit 988923b

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎pkg/engine/scan_test.go‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -320,7 +320,7 @@ func TestNoGoroutineLeakOnPrematureCancel(t *testing.T) {
320320

321321
after := runtime.NumGoroutine()
322322
leak := after - before
323-
if leak > 2 { // tolerance for test harness goroutines
323+
if leak > 3 { // tolerance for test harness goroutines
324324
t.Errorf("goroutine leak detected: %d goroutines created and not cleaned up", leak)
325325
}
326326
}

0 commit comments

Comments
 (0)