Repository navigation
test(worker): assert the timeout contract instead of driver log timing - #45
Merged
Merged
Conversation
The hung-command test required two logged driver calls, but the fake logs a call only when its stdin ends, and on a loaded host the 200 ms timeout kills the hung command before that (40 of 48 concurrent runs failed). It now asserts that the command is never replayed and that exactly one status probe follows the timeout.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Defect
extensions/oracle/worker/agent-browser-helpers.test.mjs› "hung command has a bounded typed timeout" required exactly two logged driver calls. The fake driver logs a call when its stdin ends, and the runner kills the hungsnapshot -iafter 200 ms. On a loaded host that process is often killed before Node has started and logged it, so only the status probe appears (1 !== 2). It failed once in a fullverify:oraclerun during the archive work (#41).Fix
The test now asserts the runner's contract instead of the fake's log timing:
--json stream statusprobe follows the timeout.The typed-error and elapsed-time assertions are unchanged.
Verification
npm run verify:oraclepasses.