diff options
author | Tavian Barnes <tavianator@tavianator.com> | 2023-11-07 13:10:44 -0500 |
---|---|---|
committer | Tavian Barnes <tavianator@tavianator.com> | 2023-11-07 13:19:08 -0500 |
commit | 163baf1c9af13be0ce705b133e41e0c3d6427398 (patch) | |
tree | 64827684a24c345f436d1135b5b4fbe92933bd47 /tests | |
parent | ce90dc9bc00c46b27b437467bb2f053ab2307fbc (diff) | |
download | bfs-163baf1c9af13be0ce705b133e41e0c3d6427398.tar.xz |
parse: Reject -{exec,ok}dir if $PATH contains a relative path
This matches the behaviour of GNU find.
Diffstat (limited to 'tests')
-rw-r--r-- | tests/gnu/execdir_path_dot.sh | 1 | ||||
-rw-r--r-- | tests/gnu/execdir_path_empty.sh | 1 | ||||
-rw-r--r-- | tests/gnu/execdir_path_relative.sh | 1 | ||||
-rw-r--r-- | tests/gnu/okdir_path_dot.sh | 1 | ||||
-rw-r--r-- | tests/gnu/okdir_path_empty.sh | 1 | ||||
-rw-r--r-- | tests/gnu/okdir_path_relative.sh | 1 |
6 files changed, 6 insertions, 0 deletions
diff --git a/tests/gnu/execdir_path_dot.sh b/tests/gnu/execdir_path_dot.sh new file mode 100644 index 0000000..632dbb4 --- /dev/null +++ b/tests/gnu/execdir_path_dot.sh @@ -0,0 +1 @@ +! PATH=".:$PATH" invoke_bfs basic -execdir echo {} + diff --git a/tests/gnu/execdir_path_empty.sh b/tests/gnu/execdir_path_empty.sh new file mode 100644 index 0000000..eda6b1c --- /dev/null +++ b/tests/gnu/execdir_path_empty.sh @@ -0,0 +1 @@ +! PATH=":$PATH" invoke_bfs basic -execdir echo {} + diff --git a/tests/gnu/execdir_path_relative.sh b/tests/gnu/execdir_path_relative.sh new file mode 100644 index 0000000..69899ad --- /dev/null +++ b/tests/gnu/execdir_path_relative.sh @@ -0,0 +1 @@ +! PATH="foo:$PATH" invoke_bfs basic -execdir echo {} + diff --git a/tests/gnu/okdir_path_dot.sh b/tests/gnu/okdir_path_dot.sh new file mode 100644 index 0000000..5b40e27 --- /dev/null +++ b/tests/gnu/okdir_path_dot.sh @@ -0,0 +1 @@ +! PATH=".:$PATH" invoke_bfs basic -okdir echo {} \; diff --git a/tests/gnu/okdir_path_empty.sh b/tests/gnu/okdir_path_empty.sh new file mode 100644 index 0000000..2669ee8 --- /dev/null +++ b/tests/gnu/okdir_path_empty.sh @@ -0,0 +1 @@ +! PATH=":$PATH" invoke_bfs basic -okdir echo {} \; diff --git a/tests/gnu/okdir_path_relative.sh b/tests/gnu/okdir_path_relative.sh new file mode 100644 index 0000000..05100a1 --- /dev/null +++ b/tests/gnu/okdir_path_relative.sh @@ -0,0 +1 @@ +! PATH="foo:$PATH" invoke_bfs basic -okdir echo {} \; |