The timing check only has to sit under the timeout

Two seconds was measured on one warm machine and has no margin against the
6.8s cold build listening already records. The status and the absence of the
frame-boundary sentence are what discriminate; this bound exists only so a
timeout cannot be read as an answer, so it moves to 4.5 and says so.
This commit is contained in:
Joseph Ferano 2026-09-18 07:40:55 +07:00
parent 0c0eadb424
commit 95058502f5

View File

@ -2354,11 +2354,16 @@ let () =
fail fail
"a printing program was diagnosed as one that is not polling, which \ "a printing program was diagnosed as one that is not polling, which \
is the defect and not the symptom"; is the defect and not the symptom";
(* The wait is five seconds, so anything near it is the timeout being (* The only job this number has is to sit under the daemon's own
reached rather than a slow machine. Two is the compromise: a cold five-second wait, so that "it answered" and "it gave up" cannot be
[llc] under dune's own parallelism is comfortably inside it, and a confused. It is not a measurement of how fast a module builds, and it
run that blocked is comfortably outside. *) is deliberately not tightened into one: [listening] above records 6.8s
if took > 2.0 then for a cold build under dune's parallelism, and a suite that goes red
on a loaded machine teaches whoever is running it to skim past red.
The two assertions that actually discriminate are the status and the
absence of the frame-boundary sentence; this one only rules out a
timeout that somehow reported success. *)
if took > 4.5 then
fail "evaluating against a printing program took %.1fs" took; fail "evaluating against a printing program took %.1fs" took;
(* And the program's own text came back on the reply rather than being (* And the program's own text came back on the reply rather than being
drained into nothing. *) drained into nothing. *)