You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Replace bare grep with test_grep in test assertions across the
suite. test_grep prints the contents of the file being searched
on failure, making debugging easier than a bare grep which fails
silently.
Only assertion-style greps are converted: grep used as a filter
in pipelines, command substitutions, conditionals, or with
redirected I/O is left as-is. Existing '! test_grep' calls are
rewritten to 'test_grep !' so that the diagnostic output is
preserved on failure.
This patch was produced using check-grep.pl (added in the next
commit) to identify bare grep assertions, and then applying
substitutions to the flagged lines. A handful of greps with
backslash-continuation line offsets were fixed manually.
To verify, apply the next commit and run:
make -C t test-lint-grep
Signed-off-by: Michael Montalbo <mmontalbo@gmail.com>
0 commit comments