Bound static-bin smoke tests with per-test timeout#6
Merged
Conversation
Wrap every guest-binary invocation in timeout TEST_TIMEOUT (default 10s, override via env) so a regression that hangs a guest binary (futex deadlock, EPOLLET busy-loop, blocking syscall miswire) cannot stall "make check" indefinitely. Surface the GNU-timeout rc=124 as a distinct " (timeout)" failure instead of letting it fall through to the generic "pattern not found, rc=124" path; the two have different root causes (livelock vs. semantic regression) and deserve different signal in CI logs. Fail upfront with a clear message when 'timeout' is missing from PATH, so an absent Homebrew coreutils install produces one error rather than every test reporting "command not found, rc=127". Use integer compare on the rc check, and apply the wrapper uniformly across srun_check, srun_pipe, srun_script, and the two inlined diff cases.
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.
Wrap every guest-binary invocation in timeout TEST_TIMEOUT (default 10s, override via env) so a regression that hangs a guest binary (futex deadlock, EPOLLET busy-loop, blocking syscall miswire) cannot stall "make check" indefinitely. Surface the GNU-timeout rc=124 as a distinct " (timeout)" failure instead of letting it fall through to the generic "pattern not found, rc=124" path; the two have different root causes (livelock vs. semantic regression) and deserve different signal in CI logs.
Fail upfront with a clear message when 'timeout' is missing from PATH, so an absent Homebrew coreutils install produces one error rather than every test reporting "command not found, rc=127".
Use integer compare on the rc check, and apply the wrapper uniformly across srun_check, srun_pipe, srun_script, and the two inlined diff cases.
Summary by cubic
Add a per-test timeout to static-bin smoke tests to prevent hangs and make CI failures clearer. Default is 10s via
TEST_TIMEOUT; timeouts are labeled explicitly and we fail fast iftimeoutis missing.timeoutusingTEST_TIMEOUT(default 10s, override via env).timeoutis not on PATH (e.g., missing Homebrewcoreutilson macOS).srun_check,srun_pipe,srun_script, and inlinediffchecks.result=15.Written for commit f0e021e. Summary will update on new commits.