aboutsummaryrefslogtreecommitdiff
path: root/tests/grep.test
AgeCommit message (Collapse)Author
2021-01-23Fix grep bug where -f /dev/null added "" regex matching everything,Rob Landley
and address TODO where -z was still splitting patterns on \n
2019-10-28Only create test file "input" when input argument isn't empty.Rob Landley
2019-07-16Fix unaligned access, tweak test suite.Rob Landley
2019-07-16grep: fix two bugs found by hwasan.Elliott Hughes
The first bug appeared as a memory overwrite, but was actually visible without hwasan: basically any `grep -F` that let to multiple matches on the same line was broken. The second bug was another memory overwrite, visible when I ran the existing grep tests. Bug: http://b/137573082
2019-07-12grep: add -R as well as -r.Elliott Hughes
On BSD these are actually the same, and there's a -S that you need in addition. So strictly this is a behavior change for Android (which is going from BSD grep to toybox grep), but it's a behavior preserving change for the AOSP build (which is going from GNU grep to toybox grep), and the latter actually has a checked-in use of -R where the former doesn't.
2019-05-25grep: add --exclude-dir.Elliott Hughes
Used quite a lot, especially with `--exclude-dir=.git`.
2019-05-17Fix a missing else, and an inverted test hidden by the missing else.Rob Landley
Add test to show failure case.
2019-03-14I had some pending grep tests I hadn't checked in too.Rob Landley
2019-03-14grep: use TOYFLAG_ARGFAIL for grep too.Elliott Hughes
Also add a test, and add a test for timeout now it's been fixed.
2018-12-18Add grep tests to "make tests".Rob Landley
2018-12-17A couple more grep tests, and slightly use dlist_terminate() for the loops.Rob Landley
2018-11-20Chmod +x tests that pass with VERBOSE=fail and -x on tests needing work.Rob Landley
2018-08-04Add tests for grep with implicit/explicit BREs and explicit EREs.Elliott Hughes
This is in POSIX, but pcre2grep gets it wrong (https://bugs.exim.org/show_bug.cgi?id=2294).
2016-07-23Many failing tests I need to fix grep to pass while adding --color.Rob Landley
2016-03-02Factor out command name at the start of test name, have runtest.sh print it.Rob Landley
2016-02-04Fix -H and -n with -ABC, and add tests.Rob Landley
2016-01-30Add grep -B -CRob Landley
2016-01-30Add grep -ARob Landley
2015-11-01Change grep -w to checking matches after the fact rather than modifing regex.Rob Landley
This lets '(x)\1' match, as reported by Isabella Parakiss.
2014-09-20Move testsuite out of scripts/test into its own top level tests directory, ↵Rob Landley
and make ctrl-c kill "make test" more reliably.