fuzz: add differential fuzzer against GNU grep#7
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #7 +/- ##
=======================================
Coverage 95.28% 95.28%
=======================================
Files 6 6
Lines 1422 1422
Branches 140 140
=======================================
Hits 1355 1355
Misses 66 66
Partials 1 1
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
096a6f8 to
8037f67
Compare
lhecker
left a comment
There was a problem hiding this comment.
I believe most of this is adopted from the coreutils repo, right? I saw similar code there as well.
Personally speaking, I think some of the text feels somewhat verbose. And as a Windows Terminal maintainer, I also always get a bit squirmish when I see crates like console being used. Their Windows implementation is usually not great and somewhat bodgy.
Add a cargo-fuzz harness (fuzz_grep) that runs uu_grep and GNU grep on the same generated args/input and panics on any divergence, using the vendored uufuzz crate (adapted from uutils/coreutils to depend on crates.io uucore rather than a path). A CI workflow (.github/workflows/fuzzing.yml) builds the uufuzz examples, builds the fuzzer, and runs it for 60s. fuzz_grep is marked should_pass: false / continue-on-error since it currently surfaces real GNU-compatibility gaps (e.g. uu_grep rejects a repeated -m, GNU accepts).
8037f67 to
9598faf
Compare
Merging this PR will not alter performance
Comparing Footnotes
|
Add a cargo-fuzz harness (fuzz_grep) that runs uu_grep and GNU grep on the same generated args/input and panics on any divergence, using the vendored uufuzz crate (adapted from uutils/coreutils to depend on crates.io uucore rather than a path).
A CI workflow (.github/workflows/fuzzing.yml) builds the uufuzz examples, builds the fuzzer, and runs it for 60s. fuzz_grep is marked should_pass: false / continue-on-error since it currently surfaces real GNU-compatibility gaps (e.g. uu_grep rejects a repeated -m, GNU accepts).