Make the tests pass on a busy host (closes #240)
check / check (push) Canceled after 0s

Tests that waited a few seconds for something to happen now wait 15 seconds.
The wait ends as soon as the condition holds, so a passing run takes no longer.

TestStreamNotDroppedWhileLinesArrive, and the tests whose requests pass a 2- or
4-second limit in the server, run on a fake clock, so a stall on the host
cannot use up the limit.

The checkpoint tests give the writing connection a 30-second busy timeout, so
their limit can be 15 seconds and a checkpoint that waits for a read still
fails them.

Model: opus-5-5
This commit is contained in:
sneak committed 2026-11-10 10:05:45 +00:00
1 parent cf50d195ad
commit cf30c7460c
10 files changed
+249 -121

No files matched your search

+2 -2
View File
@@ -22,10 +22,10 @@ func TestStopClosesTheConnectionOfARequestStillRunning(t *testing.T) {
stopDeadline = 100 * time.Millisecond
// waitTimeout is how long the test waits for the request to reach
// the handler, and then for the client to see its connection closed.
waitTimeout = 2 * time.Second
waitTimeout = 15 * time.Second
// readHeaderTimeout bounds the test server's read of the request
// header, as every http.Server must.
readHeaderTimeout = time.Second
readHeaderTimeout = waitTimeout
)
release := make(chan struct{})