diff options
author | Tavian Barnes <tavianator@tavianator.com> | 2022-02-04 11:23:27 -0500 |
---|---|---|
committer | Tavian Barnes <tavianator@tavianator.com> | 2022-02-04 11:28:22 -0500 |
commit | 2d4d6787c4bc62042be4a58a4791074ab2c6a89e (patch) | |
tree | 0753c783533afc2bc3362f73ba3e8c2e45f1e65b /tests.sh | |
parent | d83ffb41c7f5d42bfb43a19e38ab3d1331f0d86e (diff) | |
download | bfs-2d4d6787c4bc62042be4a58a4791074ab2c6a89e.tar.xz |
regex: Add support for emacs and grep types
Diffstat (limited to 'tests.sh')
-rwxr-xr-x | tests.sh | 18 |
1 files changed, 18 insertions, 0 deletions
@@ -624,6 +624,8 @@ gnu_tests=( test_regextype_posix_basic test_regextype_posix_extended test_regextype_ed + test_regextype_emacs + test_regextype_grep test_regextype_sed test_samefile @@ -2107,6 +2109,22 @@ function test_regextype_ed() { bfs_diff -regextype ed -regex '\./\((\)' } +function test_regextype_emacs() { + if fail quiet invoke_bfs -regextype emacs -quit; then + return 0 + fi + + bfs_diff basic -regextype emacs -regex '.*/\(f+o?o?\|bar\)' +} + +function test_regextype_grep() { + if fail quiet invoke_bfs -regextype grep -quit; then + return 0 + fi + + bfs_diff basic -regextype grep -regex '.*/f\+o\?o\?' +} + function test_regextype_sed() { cd weirdnames bfs_diff -regextype sed -regex '\./\((\)' |