]> git.99rst.org Git - git.git/commitdiff
t1001: replace 'test -f' with 'test_path_is_file'
authorRodrigo Carvalho <redacted>
Sat, 10 May 2025 23:09:09 +0000 (20:09 -0300)
committerJunio C Hamano <redacted>
Mon, 12 May 2025 17:09:21 +0000 (10:09 -0700)
'test_path_is_file' is a modern path checking method in Git's development.
 Replace the basic shell command 'test -f' with this approach.

Signed-off-by: Rodrigo Carvalho <redacted>
Signed-off-by: Junio C Hamano <redacted>
t/t1001-read-tree-m-2way.sh

index 88c524f6558eedd0775da7500d84a90ba19edeba..59b8e56058e017921f881c2f870fe5bf30bf55c1 100755 (executable)
@@ -363,7 +363,7 @@ test_expect_success 'a/b (untracked) vs a case setup.' '
 test_expect_success 'a/b (untracked) vs a, plus c/d case test.' '
        read_tree_u_must_fail -u -m "$treeH" "$treeM" &&
        git ls-files --stage &&
-       test -f a/b
+       test_path_is_file a/b
 '
 
 test_expect_success 'read-tree supports the super-prefix' '
git clone https://git.99rst.org/PROJECT