]> git.ipfire.org Git - thirdparty/git.git/commitdiff
t5403: use test_path_is_file instead of test -f
authorDeveshi Dwivedi <deveshigurgaon@gmail.com>
Mon, 29 Dec 2025 18:57:37 +0000 (18:57 +0000)
committerJunio C Hamano <gitster@pobox.com>
Tue, 30 Dec 2025 00:23:00 +0000 (09:23 +0900)
Replace 'test -f' with the test_path_is_file in
t5403-post-checkout-hook.sh. This helper provides better error
messages when tests fail, making it easier to debug issues.

Signed-off-by: Deveshi Dwivedi <deveshigurgaon@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t/t5403-post-checkout-hook.sh

index cfaae547398e0e54cfc5b8f6403d2502ac826782..ade9e5087f9f30fadddac9fdce78695f2a8350a6 100755 (executable)
@@ -110,7 +110,7 @@ test_expect_success 'post-checkout hook is triggered by clone' '
        echo "$@" >"$GIT_DIR/post-checkout.args"
        EOF
        git clone --template=templates . clone3 &&
-       test -f clone3/.git/post-checkout.args
+       test_path_is_file clone3/.git/post-checkout.args
 '
 
 test_done