From 071f2e36bcbaf81ed4ebed2e272afe483849b5b0 Mon Sep 17 00:00:00 2001 From: Roger Koranteng Date: Tue, 20 Oct 2026 09:26:27 +0000 Subject: [PATCH] t5301: use test_path_is_file instead of test -f Replace raw 'test -f' assertions with the 'test_path_is_file' helper, which gives diagnostic output when the assertion fails. Signed-off-by: Roger Koranteng Signed-off-by: Junio C Hamano --- t/t5301-sliding-window.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/t/t5301-sliding-window.sh b/t/t5301-sliding-window.sh index 3c3666b278..b6868229bf 100755 --- a/t/t5301-sliding-window.sh +++ b/t/t5301-sliding-window.sh @@ -22,7 +22,7 @@ test_expect_success 'setup' ' git repack -a -d && test "$(git count-objects)" = "0 objects, 0 kilobytes" && pack1=$(ls .git/objects/pack/*.pack) && - test -f "$pack1" + test_path_is_file "$pack1" ' test_expect_success 'verify-pack -v, defaults' ' @@ -48,7 +48,7 @@ test_expect_success 'repack -a -d, packedGit{WindowSize,Limit} == 1 page' ' git repack -a -d && test "$(git count-objects)" = "0 objects, 0 kilobytes" && pack2=$(ls .git/objects/pack/*.pack) && - test -f "$pack2" && + test_path_is_file "$pack2" && test "$pack1" \!= "$pack2" '