From fa24499735018e2cb81a6a76aa8b5e72695fb8ad Mon Sep 17 00:00:00 2001 From: Tavian Barnes Date: Mon, 27 May 2024 16:56:43 -0400 Subject: Implement the remaining regex types Closes: https://github.com/tavianator/bfs/issues/21 --- tests/gnu/regextype_awk.out | 2 ++ tests/gnu/regextype_awk.sh | 3 +++ tests/gnu/regextype_egrep.out | 0 tests/gnu/regextype_egrep.sh | 3 +++ tests/gnu/regextype_findutils_default.out | 3 +++ tests/gnu/regextype_findutils_default.sh | 3 +++ tests/gnu/regextype_gnu_awk.out | 2 ++ tests/gnu/regextype_gnu_awk.sh | 3 +++ tests/gnu/regextype_posix_awk.out | 2 ++ tests/gnu/regextype_posix_awk.sh | 3 +++ tests/gnu/regextype_posix_minimal_basic.out | 1 + tests/gnu/regextype_posix_minimal_basic.sh | 2 ++ 12 files changed, 27 insertions(+) create mode 100644 tests/gnu/regextype_awk.out create mode 100644 tests/gnu/regextype_awk.sh create mode 100644 tests/gnu/regextype_egrep.out create mode 100644 tests/gnu/regextype_egrep.sh create mode 100644 tests/gnu/regextype_findutils_default.out create mode 100644 tests/gnu/regextype_findutils_default.sh create mode 100644 tests/gnu/regextype_gnu_awk.out create mode 100644 tests/gnu/regextype_gnu_awk.sh create mode 100644 tests/gnu/regextype_posix_awk.out create mode 100644 tests/gnu/regextype_posix_awk.sh create mode 100644 tests/gnu/regextype_posix_minimal_basic.out create mode 100644 tests/gnu/regextype_posix_minimal_basic.sh (limited to 'tests') diff --git a/tests/gnu/regextype_awk.out b/tests/gnu/regextype_awk.out new file mode 100644 index 0000000..0f32fc4 --- /dev/null +++ b/tests/gnu/regextype_awk.out @@ -0,0 +1,2 @@ +weirdnames/*/m +weirdnames/[/k diff --git a/tests/gnu/regextype_awk.sh b/tests/gnu/regextype_awk.sh new file mode 100644 index 0000000..3718473 --- /dev/null +++ b/tests/gnu/regextype_awk.sh @@ -0,0 +1,3 @@ +invoke_bfs -regextype awk -quit || skip + +bfs_diff weirdnames -regextype awk -regex '.*/[\[\*]/.*' diff --git a/tests/gnu/regextype_egrep.out b/tests/gnu/regextype_egrep.out new file mode 100644 index 0000000..e69de29 diff --git a/tests/gnu/regextype_egrep.sh b/tests/gnu/regextype_egrep.sh new file mode 100644 index 0000000..281d9c0 --- /dev/null +++ b/tests/gnu/regextype_egrep.sh @@ -0,0 +1,3 @@ +invoke_bfs -regextype egrep -quit || skip + +bfs_diff weirdnames -regextype egrep -regex '*.*/{l' diff --git a/tests/gnu/regextype_findutils_default.out b/tests/gnu/regextype_findutils_default.out new file mode 100644 index 0000000..709a7ba --- /dev/null +++ b/tests/gnu/regextype_findutils_default.out @@ -0,0 +1,3 @@ +/n +weirdnames/ +weirdnames/*/m diff --git a/tests/gnu/regextype_findutils_default.sh b/tests/gnu/regextype_findutils_default.sh new file mode 100644 index 0000000..c870312 --- /dev/null +++ b/tests/gnu/regextype_findutils_default.sh @@ -0,0 +1,3 @@ +invoke_bfs -regextype findutils-default -quit || skip + +bfs_diff weirdnames -regextype findutils-default -regex '.*/./\(m\|n\)' diff --git a/tests/gnu/regextype_gnu_awk.out b/tests/gnu/regextype_gnu_awk.out new file mode 100644 index 0000000..0f32fc4 --- /dev/null +++ b/tests/gnu/regextype_gnu_awk.out @@ -0,0 +1,2 @@ +weirdnames/*/m +weirdnames/[/k diff --git a/tests/gnu/regextype_gnu_awk.sh b/tests/gnu/regextype_gnu_awk.sh new file mode 100644 index 0000000..6b66496 --- /dev/null +++ b/tests/gnu/regextype_gnu_awk.sh @@ -0,0 +1,3 @@ +invoke_bfs -regextype gnu-awk -quit || skip + +bfs_diff weirdnames -regextype gnu-awk -regex '.*/[\[\*]/(\<.\>)' diff --git a/tests/gnu/regextype_posix_awk.out b/tests/gnu/regextype_posix_awk.out new file mode 100644 index 0000000..0f32fc4 --- /dev/null +++ b/tests/gnu/regextype_posix_awk.out @@ -0,0 +1,2 @@ +weirdnames/*/m +weirdnames/[/k diff --git a/tests/gnu/regextype_posix_awk.sh b/tests/gnu/regextype_posix_awk.sh new file mode 100644 index 0000000..86377d7 --- /dev/null +++ b/tests/gnu/regextype_posix_awk.sh @@ -0,0 +1,3 @@ +invoke_bfs -regextype posix-awk -quit || skip + +bfs_diff weirdnames -regextype posix-awk -regex '.*/[\[\*]/.*' diff --git a/tests/gnu/regextype_posix_minimal_basic.out b/tests/gnu/regextype_posix_minimal_basic.out new file mode 100644 index 0000000..0f0971e --- /dev/null +++ b/tests/gnu/regextype_posix_minimal_basic.out @@ -0,0 +1 @@ +./( diff --git a/tests/gnu/regextype_posix_minimal_basic.sh b/tests/gnu/regextype_posix_minimal_basic.sh new file mode 100644 index 0000000..ee324f3 --- /dev/null +++ b/tests/gnu/regextype_posix_minimal_basic.sh @@ -0,0 +1,2 @@ +cd weirdnames +bfs_diff -regextype posix-minimal-basic -regex '\./\((\)' -- cgit v1.2.3