close
Skip to content

Fix dd integration tests, add MUST-tier conv= coverage#34

Open
kelp wants to merge 1 commit intomainfrom
worktree-agent-a9fa6f63
Open

Fix dd integration tests, add MUST-tier conv= coverage#34
kelp wants to merge 1 commit intomainfrom
worktree-agent-a9fa6f63

Conversation

@kelp
Copy link
Copy Markdown
Owner

@kelp kelp commented Apr 2, 2026

Summary

  • Fixed 5 broken integration tests that compared against macOS /usr/bin/dd (which produced empty output). Replaced with hardcoded expected values matching GNU dd behavior.
  • Added 9 new integration tests covering MUST-tier conv= values: sync (NUL padding + full block), notrunc/truncate contrast, fsync, osync, ascii, ebcdic, ibm, and noerror.
  • Total dd integration test count went from 31 to 40, all passing.

Context

The code audit found that 11 MUST-tier conv= values had zero integration tests. Investigation revealed that conv=sync, conv=notrunc, and conv=ibm were already implemented correctly in the source code, but the integration tests that were supposed to verify them compared against macOS system dd output, which produced empty results.

Test plan

  • just fmt -- no changes
  • zig build test --summary all -- all unit tests pass
  • just it-util dd -- 40/40 integration tests pass

Five tests compared against macOS /usr/bin/dd which produced
empty output, causing false failures. Replaced with hardcoded
expected values matching GNU dd behavior.

Added 9 integration tests for MUST-tier conv= values: sync
(NUL padding), sync (full block), notrunc/truncate contrast,
fsync, osync, ascii, ebcdic, ibm, and noerror. Total coverage
went from 22 to 40 tests with all passing.
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