git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] t1001: replace 'test -f' with 'test_path_is_file'
@ 2025-05-10 23:09 Rodrigo Carvalho
  2025-05-12 17:09 ` Junio C Hamano
  0 siblings, 1 reply; 2+ messages in thread
From: Rodrigo Carvalho @ 2025-05-10 23:09 UTC (permalink / raw)
  To: git; +Cc: Rodrigo Carvalho

'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 <rodrigorsdc@gmail.com>
---
 t/t1001-read-tree-m-2way.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/t/t1001-read-tree-m-2way.sh b/t/t1001-read-tree-m-2way.sh
index 4a88bb9ef0..2e8d9384e1 100755
--- a/t/t1001-read-tree-m-2way.sh
+++ b/t/t1001-read-tree-m-2way.sh
@@ -362,7 +362,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' '
-- 
2.43.0


^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2025-05-12 17:09 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-05-10 23:09 [PATCH] t1001: replace 'test -f' with 'test_path_is_file' Rodrigo Carvalho
2025-05-12 17:09 ` Junio C Hamano

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).