summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xtests.sh25
-rw-r--r--tests/test_expr_flag_path.out2
-rw-r--r--tests/test_expr_path_flag.out2
-rw-r--r--tests/test_flag_expr_path.out2
-rw-r--r--tests/test_path_expr_flag.out2
-rw-r--r--tests/test_path_flag_expr.out2
6 files changed, 35 insertions, 0 deletions
diff --git a/tests.sh b/tests.sh
index 95e7a9f..ded74ac 100755
--- a/tests.sh
+++ b/tests.sh
@@ -295,6 +295,11 @@ bfs_tests=(
test_perm_octal_plus
test_hidden
test_nohidden
+ test_path_flag_expr
+ test_path_expr_flag
+ test_flag_expr_path
+ test_expr_flag_path
+ test_expr_path_flag
)
BSD=yes
@@ -974,6 +979,26 @@ function test_printf_leak() {
bfs_diff basic -maxdepth 0 -printf '%p'
}
+function test_path_flag_expr() {
+ bfs_diff links/h -H -type l
+}
+
+function test_path_expr_flag() {
+ bfs_diff links/h -type l -H
+}
+
+function test_flag_expr_path() {
+ bfs_diff -H -type l links/h
+}
+
+function test_expr_flag_path() {
+ bfs_diff -type l -H links/h
+}
+
+function test_expr_path_flag() {
+ bfs_diff -type l links/h -H
+}
+
result=0
for test in ${!run_*}; do
diff --git a/tests/test_expr_flag_path.out b/tests/test_expr_flag_path.out
new file mode 100644
index 0000000..c774fb9
--- /dev/null
+++ b/tests/test_expr_flag_path.out
@@ -0,0 +1,2 @@
+links/h/g
+links/h/i
diff --git a/tests/test_expr_path_flag.out b/tests/test_expr_path_flag.out
new file mode 100644
index 0000000..c774fb9
--- /dev/null
+++ b/tests/test_expr_path_flag.out
@@ -0,0 +1,2 @@
+links/h/g
+links/h/i
diff --git a/tests/test_flag_expr_path.out b/tests/test_flag_expr_path.out
new file mode 100644
index 0000000..c774fb9
--- /dev/null
+++ b/tests/test_flag_expr_path.out
@@ -0,0 +1,2 @@
+links/h/g
+links/h/i
diff --git a/tests/test_path_expr_flag.out b/tests/test_path_expr_flag.out
new file mode 100644
index 0000000..c774fb9
--- /dev/null
+++ b/tests/test_path_expr_flag.out
@@ -0,0 +1,2 @@
+links/h/g
+links/h/i
diff --git a/tests/test_path_flag_expr.out b/tests/test_path_flag_expr.out
new file mode 100644
index 0000000..c774fb9
--- /dev/null
+++ b/tests/test_path_flag_expr.out
@@ -0,0 +1,2 @@
+links/h/g
+links/h/i