add a sed fuzzer#72
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #72 +/- ##
=====================================
Coverage 0.00% 0.00%
=====================================
Files 13 13
Lines 2729 2729
Branches 240 240
=====================================
Misses 2729 2729
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:
|
| @@ -0,0 +1,264 @@ | |||
| name: Fuzzing | |||
There was a problem hiding this comment.
more or less what we have in rust coreutils
|
to run it: |
Co-authored-by: Daniel Hofstetter <daniel.hofstetter@42dh.com>
Co-authored-by: Daniel Hofstetter <daniel.hofstetter@42dh.com>
| pub fn is_gnu_cmd(cmd_path: &str) -> Result<(), std::io::Error> { | ||
| CHECK_GNU.call_once(|| { | ||
| let version_output = Command::new(cmd_path).arg("--version").output().unwrap(); | ||
|
|
||
| println!("version_output {version_output:#?}"); | ||
|
|
||
| let version_str = String::from_utf8_lossy(&version_output.stdout).to_string(); | ||
| if version_str.contains("GNU coreutils") { | ||
| IS_GNU.store(true, Ordering::Relaxed); | ||
| } | ||
| }); | ||
|
|
||
| if IS_GNU.load(Ordering::Relaxed) { | ||
| Ok(()) | ||
| } else { | ||
| panic!("Not the GNU implementation"); | ||
| } | ||
| } |
There was a problem hiding this comment.
This function probably doesn't work as expected as it relies on coreutils.
There was a problem hiding this comment.
i am planning to move this into a crate
There was a problem hiding this comment.
Co-authored-by: Daniel Hofstetter <daniel.hofstetter@42dh.com>
Co-authored-by: Daniel Hofstetter <daniel.hofstetter@42dh.com>
Co-authored-by: Daniel Hofstetter <daniel.hofstetter@42dh.com>
far from perfect
Currently:
but found:
#71