Add tests for missing features in scanner-based implementations#148
Merged
Add tests for missing features in scanner-based implementations#148
Conversation
Add six new test cases for grepdiff features that were previously untested: - grepdiff-number-files: Test -N/--number-files option - grepdiff-status: Test -s/--status option - grepdiff-include-exclude: Test -i/--include and -x/--exclude options - grepdiff-file-regex: Test -f/--file option - grepdiff-annotate: Test --annotate option - grepdiff-with-filename: Test -H/--with-filename and -h/--no-filename All tests pass with the traditional filterdiff.c implementation. With scanner-based patchfilter (--enable-scanner-patchfilter), four tests pass and two are marked as XFAIL since those features are not yet implemented in the scanner-based grepdiff: - grepdiff-status (no -s option) - grepdiff-annotate (no --annotate option) Assisted-by: Claude Code
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #148 +/- ##
==========================================
+ Coverage 85.78% 86.41% +0.62%
==========================================
Files 15 15
Lines 8112 8112
Branches 1620 1622 +2
==========================================
+ Hits 6959 7010 +51
+ Misses 1153 1102 -51
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:
|
b47a9a3 to
202c3bf
Compare
Add five new test cases for lsdiff features that were previously untested: - lsdiff-number-files: Test -N/--number-files option - lsdiff-files-range: Test -F/--files=RANGE option - lsdiff-empty-files-removed: Test -E/--empty-files-as-removed option - lsdiff-addprefix: Test --addprefix option - lsdiff-strip-match: Test -p/--strip-match option All tests pass with the traditional filterdiff.c implementation. With scanner-based patchfilter (--enable-scanner-patchfilter), four tests pass (number-files, files-range, empty-files-removed, addprefix) and one is marked as XFAIL since that feature is not yet implemented in scanner-based lsdiff (strip-match). Assisted-by: Claude Code
202c3bf to
c9dd823
Compare
Use all-local hook to ensure lsdiff and grepdiff symlinks are built during 'make', so they correctly point to filterdiff or patchfilter depending on the configuration. Previously, after reconfiguring between implementations, running 'make' would not update the symlinks, leaving them pointing to the wrong target. Also ensure the patchview directory exists before creating symlinks in it, which fixes 'make distcheck'. Assisted-by: Claude Code
c9dd823 to
d53d1ab
Compare
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.
More tests for lsdiff and grepdiff. The original implementations pass but the new scanner-based ones need work.
Also included a Makefile fix for the symlinks when switching back and forth between implementations.