]> git.ipfire.org Git - thirdparty/git.git/commitdiff
t0001: replace "test [-d|-f]" with test_path_is_* functions
authorShaoxuan Yuan <shaoxuan.yuan02@gmail.com>
Fri, 21 Jan 2022 10:21:09 +0000 (18:21 +0800)
committerJunio C Hamano <gitster@pobox.com>
Sat, 12 Feb 2022 00:38:53 +0000 (16:38 -0800)
Signed-off-by: Shaoxuan Yuan <shaoxuan.yuan02@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t/t0001-init.sh

index 3235ab4d53c9dfc282155f1da2caa44d7f40962c..d479303efa03df6f818496f1cdcafe390bee0126 100755 (executable)
@@ -6,7 +6,8 @@ TEST_PASSES_SANITIZE_LEAK=true
 . ./test-lib.sh
 
 check_config () {
-       if test -d "$1" && test -f "$1/config" && test -d "$1/refs"
+       if test_path_is_dir "$1" &&
+          test_path_is_file "$1/config" && test_path_is_dir "$1/refs"
        then
                : happy
        else