Skip to content

Add failing tests for IMPORTANT audit findings (wave 5)#11

Open
kelp wants to merge 1 commit intomainfrom
audit-wave5-failing-tests
Open

Add failing tests for IMPORTANT audit findings (wave 5)#11
kelp wants to merge 1 commit intomainfrom
audit-wave5-failing-tests

Conversation

@kelp
Copy link
Copy Markdown
Owner

@kelp kelp commented Mar 30, 2026

Summary

  • id: Tests for -z alone rejection (GNU rejects without format flag) and -a as no-op (GNU ignores, not alias for -G)
  • sleep: Tests for inf/infinity acceptance (GNU sleeps forever), error message including the invalid token
  • yes: Tests for unknown flag exit code 1 (GNU behavior, not 2) and error message including the flag name
  • timeout: Tests for --kill-after, --verbose, and --foreground flags (zero test coverage previously)

Test plan

  • Unit tests fail for the right reasons (not compile errors or hangs)
  • No test hangs (verified with timeout 120 zig build test)
  • Integration tests fail for the right reasons when run via just it
  • CI confirms failures match expected audit findings

All tests are RED (intentionally failing). Phase 2 will fix implementations.

id: -z alone accepted (GNU rejects without format flag),
-a treated as -G not no-op.
sleep: inf/infinity not accepted, error omits invalid token.
yes: unknown flag exits 2 (GNU exits 1), error omits flag name.
timeout: add --kill-after, --verbose, --foreground tests.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant