{"thread":{"id":"64725","subject":"[PATCH] [GSoC][PATCH] t9160:modernize test path checking","startedAt":"2026-01-05T14:59:57Z","lastAt":"2026-02-02T19:34:52Z","messageCount":4,"participants":["Hoda Salim via GitGitGadget","Hoda Salim","Junio C Hamano"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"533052","messageId":"pull.2160.git.git.1767625195071.gitgitgadget@gmail.com","threadId":"64725","inReplyTo":null,"subject":"[PATCH] [GSoC][PATCH] t9160:modernize test path checking","fromName":"Hoda Salim via GitGitGadget","fromEmail":"gitgitgadget@gmail.com","sentAt":"2026-01-05T14:59:55Z","receivedAt":"2026-01-05T14:59:57Z","isPatch":true,"sender":{"key":"hoda.s.salim@gmail.com","avatar":"https://avatars.githubusercontent.com/u/172552853?v=4"},"body":"From: HodaSalim <hoda.s.salim@gmail.com>\n\nReplace old-style path checks with Git's dedicated test helpers:\n- test -f → test_path_is_file\n- test -d → test_path_is_dir\n- test -s → test_file_not_empty\n\nFound using: git grep \"test -[efd]\" t/\n\nThis improves test readability and provides better error messages\nwhen path checks fail.\n\nSigned-off-by: HodaSalim <hoda.s.salim@gmail.com>\n---\n    [GSoC][PATCH] t9160:modernize test path checking\n\nPublished-As: https://github.com/gitgitgadget/git/releases/tag/pr-git-2160%2FHodaSalim%2Fmicroproject%2Fmodernize-t9160-v1\nFetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-git-2160/HodaSalim/microproject/modernize-t9160-v1\nPull-Request: https://github.com/git/git/pull/2160\n\n t/t9160-git-svn-preserve-empty-dirs.sh | 22 +++++++++++-----------\n 1 file changed, 11 insertions(+), 11 deletions(-)\n\ndiff --git a/t/t9160-git-svn-preserve-empty-dirs.sh b/t/t9160-git-svn-preserve-empty-dirs.sh\nindex 36c6b1a12f..b89c1cb93a 100755\n--- a/t/t9160-git-svn-preserve-empty-dirs.sh\n+++ b/t/t9160-git-svn-preserve-empty-dirs.sh\n@@ -61,15 +61,15 @@ test_expect_success 'clone svn repo with --preserve-empty-dirs' '\n \n # \"$GIT_REPO\"/1 should only contain the placeholder file.\n test_expect_success 'directory empty from inception' '\n-\ttest -f \"$GIT_REPO\"/1/.gitignore &&\n+\ttest_path_is_file \"$GIT_REPO\"/1/.gitignore &&\n \ttest $(find \"$GIT_REPO\"/1 -type f | wc -l) = \"1\"\n '\n \n # \"$GIT_REPO\"/2 and \"$GIT_REPO\"/3 should only contain the placeholder file.\n test_expect_success 'directory empty from subsequent svn commit' '\n-\ttest -f \"$GIT_REPO\"/2/.gitignore &&\n+\ttest_path_is_file \"$GIT_REPO\"/2/.gitignore &&\n \ttest $(find \"$GIT_REPO\"/2 -type f | wc -l) = \"1\" &&\n-\ttest -f \"$GIT_REPO\"/3/.gitignore &&\n+\ttest_path_is_file \"$GIT_REPO\"/3/.gitignore &&\n \ttest $(find \"$GIT_REPO\"/3 -type f | wc -l) = \"1\"\n '\n \n@@ -77,7 +77,7 @@ test_expect_success 'directory empty from subsequent svn commit' '\n # generated for every sub-directory at some point in the repo's history.\n test_expect_success 'add entry to previously empty directory' '\n \ttest $(find \"$GIT_REPO\"/4 -type f | wc -l) = \"1\" &&\n-\ttest -f \"$GIT_REPO\"/4/a/b/c/foo\n+\ttest_path_is_file \"$GIT_REPO\"/4/a/b/c/foo\n '\n \n # The HEAD~2 commit should not have introduced .gitignore placeholder files.\n@@ -102,14 +102,14 @@ test_expect_success 'clone svn repo with --placeholder-file specified' '\n \n # \"$GIT_REPO\"/5/.placeholder should be a file, and non-empty.\n test_expect_success 'placeholder namespace conflict with file' '\n-\ttest -s \"$GIT_REPO\"/5/.placeholder\n+\ttest_file_not_empty \"$GIT_REPO\"/5/.placeholder\n '\n \n # \"$GIT_REPO\"/6/.placeholder should be a directory, and the \"$GIT_REPO\"/6 tree\n # should only contain one file: the placeholder.\n test_expect_success 'placeholder namespace conflict with directory' '\n-\ttest -d \"$GIT_REPO\"/6/.placeholder &&\n-\ttest -f \"$GIT_REPO\"/6/.placeholder/.placeholder &&\n+\ttest_path_is_dir \"$GIT_REPO\"/6/.placeholder &&\n+\ttest_path_is_file \"$GIT_REPO\"/6/.placeholder/.placeholder &&\n \ttest $(find \"$GIT_REPO\"/6 -type f | wc -l) = \"1\"\n '\n \n@@ -134,18 +134,18 @@ test_expect_success 'second set of svn commits and rebase' '\n # Check that --preserve-empty-dirs and --placeholder-file flag state\n # stays persistent over multiple invocations.\n test_expect_success 'flag persistence during subsqeuent rebase' '\n-\ttest -f \"$GIT_REPO\"/7/.placeholder &&\n+\ttest_path_is_file \"$GIT_REPO\"/7/.placeholder &&\n \ttest $(find \"$GIT_REPO\"/7 -type f | wc -l) = \"1\"\n '\n \n # Check that placeholder files are properly removed when unnecessary,\n # even across multiple invocations.\n test_expect_success 'placeholder list persistence during subsqeuent rebase' '\n-\ttest -f \"$GIT_REPO\"/1/file1.txt &&\n+\ttest_path_is_file \"$GIT_REPO\"/1/file1.txt &&\n \ttest $(find \"$GIT_REPO\"/1 -type f | wc -l) = \"1\" &&\n \n-\ttest -f \"$GIT_REPO\"/5/file1.txt &&\n-\ttest -f \"$GIT_REPO\"/5/.placeholder &&\n+\ttest_path_is_file \"$GIT_REPO\"/5/file1.txt &&\n+\ttest_path_is_file \"$GIT_REPO\"/5/.placeholder &&\n \ttest $(find \"$GIT_REPO\"/5 -type f | wc -l) = \"2\"\n '\n \n\nbase-commit: 68cb7f9e92a5d8e9824f5b52ac3d0a9d8f653dbe\n-- \ngitgitgadget\n"},{"id":"534979","messageId":"20260202161759.84355-2-hoda.s.salim@gmail.com","threadId":"64725","inReplyTo":"pull.2160.git.git.1767625195071.gitgitgadget@gmail.com","subject":"[PATCH v2][GSoC] t9160:modernize test path checking","fromName":"Hoda Salim","fromEmail":"hoda.s.salim@gmail.com","sentAt":"2026-02-02T16:18:00Z","receivedAt":"2026-02-02T16:21:15Z","isPatch":true,"sender":{"key":"hoda.s.salim@gmail.com","avatar":"https://avatars.githubusercontent.com/u/172552853?v=4"},"body":"From: HodaSalim <hoda.s.salim@gmail.com>\n\nReplace old-style path checks with Git's dedicated test helpers:\n- test -f → test_path_is_file\n- test -d → test_path_is_dir\n- test -s → test_file_not_empty\n\nFix typos with the word \"subsequent\"\n\nFound using: git grep \"test -[efd]\" t/\n\nThis improves test readability and provides better error messages\nwhen path checks fail.\n\nSigned-off-by: HodaSalim <hoda.s.salim@gmail.com>\n---\n t/t9160-git-svn-preserve-empty-dirs.sh | 26 +++++++++++++-------------\n 1 file changed, 13 insertions(+), 13 deletions(-)\n\ndiff --git a/t/t9160-git-svn-preserve-empty-dirs.sh b/t/t9160-git-svn-preserve-empty-dirs.sh\nindex 36c6b1a12f..de32cf2542 100755\n--- a/t/t9160-git-svn-preserve-empty-dirs.sh\n+++ b/t/t9160-git-svn-preserve-empty-dirs.sh\n@@ -61,15 +61,15 @@ test_expect_success 'clone svn repo with --preserve-empty-dirs' '\n \n # \"$GIT_REPO\"/1 should only contain the placeholder file.\n test_expect_success 'directory empty from inception' '\n-\ttest -f \"$GIT_REPO\"/1/.gitignore &&\n+\ttest_path_is_file \"$GIT_REPO\"/1/.gitignore &&\n \ttest $(find \"$GIT_REPO\"/1 -type f | wc -l) = \"1\"\n '\n \n # \"$GIT_REPO\"/2 and \"$GIT_REPO\"/3 should only contain the placeholder file.\n test_expect_success 'directory empty from subsequent svn commit' '\n-\ttest -f \"$GIT_REPO\"/2/.gitignore &&\n+\ttest_path_is_file \"$GIT_REPO\"/2/.gitignore &&\n \ttest $(find \"$GIT_REPO\"/2 -type f | wc -l) = \"1\" &&\n-\ttest -f \"$GIT_REPO\"/3/.gitignore &&\n+\ttest_path_is_file \"$GIT_REPO\"/3/.gitignore &&\n \ttest $(find \"$GIT_REPO\"/3 -type f | wc -l) = \"1\"\n '\n \n@@ -77,7 +77,7 @@ test_expect_success 'directory empty from subsequent svn commit' '\n # generated for every sub-directory at some point in the repo's history.\n test_expect_success 'add entry to previously empty directory' '\n \ttest $(find \"$GIT_REPO\"/4 -type f | wc -l) = \"1\" &&\n-\ttest -f \"$GIT_REPO\"/4/a/b/c/foo\n+\ttest_path_is_file \"$GIT_REPO\"/4/a/b/c/foo\n '\n \n # The HEAD~2 commit should not have introduced .gitignore placeholder files.\n@@ -102,14 +102,14 @@ test_expect_success 'clone svn repo with --placeholder-file specified' '\n \n # \"$GIT_REPO\"/5/.placeholder should be a file, and non-empty.\n test_expect_success 'placeholder namespace conflict with file' '\n-\ttest -s \"$GIT_REPO\"/5/.placeholder\n+\ttest_file_not_empty \"$GIT_REPO\"/5/.placeholder\n '\n \n # \"$GIT_REPO\"/6/.placeholder should be a directory, and the \"$GIT_REPO\"/6 tree\n # should only contain one file: the placeholder.\n test_expect_success 'placeholder namespace conflict with directory' '\n-\ttest -d \"$GIT_REPO\"/6/.placeholder &&\n-\ttest -f \"$GIT_REPO\"/6/.placeholder/.placeholder &&\n+\ttest_path_is_dir \"$GIT_REPO\"/6/.placeholder &&\n+\ttest_path_is_file \"$GIT_REPO\"/6/.placeholder/.placeholder &&\n \ttest $(find \"$GIT_REPO\"/6 -type f | wc -l) = \"1\"\n '\n \n@@ -133,19 +133,19 @@ test_expect_success 'second set of svn commits and rebase' '\n \n # Check that --preserve-empty-dirs and --placeholder-file flag state\n # stays persistent over multiple invocations.\n-test_expect_success 'flag persistence during subsqeuent rebase' '\n-\ttest -f \"$GIT_REPO\"/7/.placeholder &&\n+test_expect_success 'flag persistence during subsequent rebase' '\n+\ttest_path_is_file \"$GIT_REPO\"/7/.placeholder &&\n \ttest $(find \"$GIT_REPO\"/7 -type f | wc -l) = \"1\"\n '\n \n # Check that placeholder files are properly removed when unnecessary,\n # even across multiple invocations.\n-test_expect_success 'placeholder list persistence during subsqeuent rebase' '\n-\ttest -f \"$GIT_REPO\"/1/file1.txt &&\n+test_expect_success 'placeholder list persistence during subsequent rebase' '\n+\ttest_path_is_file \"$GIT_REPO\"/1/file1.txt &&\n \ttest $(find \"$GIT_REPO\"/1 -type f | wc -l) = \"1\" &&\n \n-\ttest -f \"$GIT_REPO\"/5/file1.txt &&\n-\ttest -f \"$GIT_REPO\"/5/.placeholder &&\n+\ttest_path_is_file \"$GIT_REPO\"/5/file1.txt &&\n+\ttest_path_is_file \"$GIT_REPO\"/5/.placeholder &&\n \ttest $(find \"$GIT_REPO\"/5 -type f | wc -l) = \"2\"\n '\n \n-- \n2.50.1 (Apple Git-155)\n\n"},{"id":"534998","messageId":"xmqq5x8fynqy.fsf@gitster.g","threadId":"64725","inReplyTo":"20260202161759.84355-2-hoda.s.salim@gmail.com","subject":"Re: [PATCH v2][GSoC] t9160:modernize test path checking","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2026-02-02T19:00:21Z","receivedAt":"2026-02-02T19:00:24Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Hoda Salim <hoda.s.salim@gmail.com> writes:\n\n> From: HodaSalim <hoda.s.salim@gmail.com>\n>\n> Replace old-style path checks with Git's dedicated test helpers:\n> - test -f → test_path_is_file\n> - test -d → test_path_is_dir\n> - test -s → test_file_not_empty\n>\n> Fix typos with the word \"subsequent\"\n>\n> Found using: git grep \"test -[efd]\" t/\n>\n> This improves test readability and provides better error messages\n> when path checks fail.\n\nFor a small change like this, the above is sufficient as all the\nnecessary things are described, but for future reference, we prefer\nto explain things in this order:\n\n - Give an observation on how the current system works in the\n   present tense (so no need to say \"Currently X is Y\", or\n   \"Previously X was Y\" to describe the state before your change;\n   just \"X is Y\" is enough), and discuss what you perceive as a\n   problem in it.\n\n - Propose a solution (optional---often, problem description\n   trivially leads to an obvious solution in reader's minds).\n\n - Give commands to somebody editing the codebase to \"make it so\",\n   instead of saying \"This commit does X\".\n\nYou are going backwards ;-).\n\nWill queue.  Thanks (and thanks for all the reviewers who helped\npolish the draft to get to this v2).\n\n\n>\n> Signed-off-by: HodaSalim <hoda.s.salim@gmail.com>\n> ---\n>  t/t9160-git-svn-preserve-empty-dirs.sh | 26 +++++++++++++-------------\n>  1 file changed, 13 insertions(+), 13 deletions(-)\n>\n> diff --git a/t/t9160-git-svn-preserve-empty-dirs.sh b/t/t9160-git-svn-preserve-empty-dirs.sh\n> index 36c6b1a12f..de32cf2542 100755\n> --- a/t/t9160-git-svn-preserve-empty-dirs.sh\n> +++ b/t/t9160-git-svn-preserve-empty-dirs.sh\n> @@ -61,15 +61,15 @@ test_expect_success 'clone svn repo with --preserve-empty-dirs' '\n>  \n>  # \"$GIT_REPO\"/1 should only contain the placeholder file.\n>  test_expect_success 'directory empty from inception' '\n> -\ttest -f \"$GIT_REPO\"/1/.gitignore &&\n> +\ttest_path_is_file \"$GIT_REPO\"/1/.gitignore &&\n>  \ttest $(find \"$GIT_REPO\"/1 -type f | wc -l) = \"1\"\n>  '\n>  \n>  # \"$GIT_REPO\"/2 and \"$GIT_REPO\"/3 should only contain the placeholder file.\n>  test_expect_success 'directory empty from subsequent svn commit' '\n> -\ttest -f \"$GIT_REPO\"/2/.gitignore &&\n> +\ttest_path_is_file \"$GIT_REPO\"/2/.gitignore &&\n>  \ttest $(find \"$GIT_REPO\"/2 -type f | wc -l) = \"1\" &&\n> -\ttest -f \"$GIT_REPO\"/3/.gitignore &&\n> +\ttest_path_is_file \"$GIT_REPO\"/3/.gitignore &&\n>  \ttest $(find \"$GIT_REPO\"/3 -type f | wc -l) = \"1\"\n>  '\n>  \n> @@ -77,7 +77,7 @@ test_expect_success 'directory empty from subsequent svn commit' '\n>  # generated for every sub-directory at some point in the repo's history.\n>  test_expect_success 'add entry to previously empty directory' '\n>  \ttest $(find \"$GIT_REPO\"/4 -type f | wc -l) = \"1\" &&\n> -\ttest -f \"$GIT_REPO\"/4/a/b/c/foo\n> +\ttest_path_is_file \"$GIT_REPO\"/4/a/b/c/foo\n>  '\n>  \n>  # The HEAD~2 commit should not have introduced .gitignore placeholder files.\n> @@ -102,14 +102,14 @@ test_expect_success 'clone svn repo with --placeholder-file specified' '\n>  \n>  # \"$GIT_REPO\"/5/.placeholder should be a file, and non-empty.\n>  test_expect_success 'placeholder namespace conflict with file' '\n> -\ttest -s \"$GIT_REPO\"/5/.placeholder\n> +\ttest_file_not_empty \"$GIT_REPO\"/5/.placeholder\n>  '\n>  \n>  # \"$GIT_REPO\"/6/.placeholder should be a directory, and the \"$GIT_REPO\"/6 tree\n>  # should only contain one file: the placeholder.\n>  test_expect_success 'placeholder namespace conflict with directory' '\n> -\ttest -d \"$GIT_REPO\"/6/.placeholder &&\n> -\ttest -f \"$GIT_REPO\"/6/.placeholder/.placeholder &&\n> +\ttest_path_is_dir \"$GIT_REPO\"/6/.placeholder &&\n> +\ttest_path_is_file \"$GIT_REPO\"/6/.placeholder/.placeholder &&\n>  \ttest $(find \"$GIT_REPO\"/6 -type f | wc -l) = \"1\"\n>  '\n>  \n> @@ -133,19 +133,19 @@ test_expect_success 'second set of svn commits and rebase' '\n>  \n>  # Check that --preserve-empty-dirs and --placeholder-file flag state\n>  # stays persistent over multiple invocations.\n> -test_expect_success 'flag persistence during subsqeuent rebase' '\n> -\ttest -f \"$GIT_REPO\"/7/.placeholder &&\n> +test_expect_success 'flag persistence during subsequent rebase' '\n> +\ttest_path_is_file \"$GIT_REPO\"/7/.placeholder &&\n>  \ttest $(find \"$GIT_REPO\"/7 -type f | wc -l) = \"1\"\n>  '\n>  \n>  # Check that placeholder files are properly removed when unnecessary,\n>  # even across multiple invocations.\n> -test_expect_success 'placeholder list persistence during subsqeuent rebase' '\n> -\ttest -f \"$GIT_REPO\"/1/file1.txt &&\n> +test_expect_success 'placeholder list persistence during subsequent rebase' '\n> +\ttest_path_is_file \"$GIT_REPO\"/1/file1.txt &&\n>  \ttest $(find \"$GIT_REPO\"/1 -type f | wc -l) = \"1\" &&\n>  \n> -\ttest -f \"$GIT_REPO\"/5/file1.txt &&\n> -\ttest -f \"$GIT_REPO\"/5/.placeholder &&\n> +\ttest_path_is_file \"$GIT_REPO\"/5/file1.txt &&\n> +\ttest_path_is_file \"$GIT_REPO\"/5/.placeholder &&\n>  \ttest $(find \"$GIT_REPO\"/5 -type f | wc -l) = \"2\"\n>  '\n"},{"id":"535005","messageId":"CAAGT0iJuV+L52Fnme-LbNXUtUpSqmeX6+5SYKGZE9fxzHEuNGg@mail.gmail.com","threadId":"64725","inReplyTo":"xmqq5x8fynqy.fsf@gitster.g","subject":"Re: [PATCH v2][GSoC] t9160:modernize test path checking","fromName":"Hoda Salim","fromEmail":"hoda.s.salim@gmail.com","sentAt":"2026-02-02T19:34:39Z","receivedAt":"2026-02-02T19:34:52Z","isPatch":true,"sender":{"key":"hoda.s.salim@gmail.com","avatar":"https://avatars.githubusercontent.com/u/172552853?v=4"},"body":"> Will queue.  Thanks (and thanks for all the reviewers who helped\n> polish the draft to get to this v2).\n\nYeah, sorry about that. The patch was initially submitted using\nGitGitGadget and I didn't really do a great job in the beginning to\nreply to the GitGitGadget email.\nPushkar was the maintainer that kindly pointed out the misspelling. I\nadded him to the CC for visibility\n\nThank You,\nHoda\n\n\nOn Mon, Feb 2, 2026 at 9:00 PM Junio C Hamano <gitster@pobox.com> wrote:\n>\n> Hoda Salim <hoda.s.salim@gmail.com> writes:\n>\n> > From: HodaSalim <hoda.s.salim@gmail.com>\n> >\n> > Replace old-style path checks with Git's dedicated test helpers:\n> > - test -f → test_path_is_file\n> > - test -d → test_path_is_dir\n> > - test -s → test_file_not_empty\n> >\n> > Fix typos with the word \"subsequent\"\n> >\n> > Found using: git grep \"test -[efd]\" t/\n> >\n> > This improves test readability and provides better error messages\n> > when path checks fail.\n>\n> For a small change like this, the above is sufficient as all the\n> necessary things are described, but for future reference, we prefer\n> to explain things in this order:\n>\n>  - Give an observation on how the current system works in the\n>    present tense (so no need to say \"Currently X is Y\", or\n>    \"Previously X was Y\" to describe the state before your change;\n>    just \"X is Y\" is enough), and discuss what you perceive as a\n>    problem in it.\n>\n>  - Propose a solution (optional---often, problem description\n>    trivially leads to an obvious solution in reader's minds).\n>\n>  - Give commands to somebody editing the codebase to \"make it so\",\n>    instead of saying \"This commit does X\".\n>\n> You are going backwards ;-).\n>\n> Will queue.  Thanks (and thanks for all the reviewers who helped\n> polish the draft to get to this v2).\n>\n>\n> >\n> > Signed-off-by: HodaSalim <hoda.s.salim@gmail.com>\n> > ---\n> >  t/t9160-git-svn-preserve-empty-dirs.sh | 26 +++++++++++++-------------\n> >  1 file changed, 13 insertions(+), 13 deletions(-)\n> >\n> > diff --git a/t/t9160-git-svn-preserve-empty-dirs.sh b/t/t9160-git-svn-preserve-empty-dirs.sh\n> > index 36c6b1a12f..de32cf2542 100755\n> > --- a/t/t9160-git-svn-preserve-empty-dirs.sh\n> > +++ b/t/t9160-git-svn-preserve-empty-dirs.sh\n> > @@ -61,15 +61,15 @@ test_expect_success 'clone svn repo with --preserve-empty-dirs' '\n> >\n> >  # \"$GIT_REPO\"/1 should only contain the placeholder file.\n> >  test_expect_success 'directory empty from inception' '\n> > -     test -f \"$GIT_REPO\"/1/.gitignore &&\n> > +     test_path_is_file \"$GIT_REPO\"/1/.gitignore &&\n> >       test $(find \"$GIT_REPO\"/1 -type f | wc -l) = \"1\"\n> >  '\n> >\n> >  # \"$GIT_REPO\"/2 and \"$GIT_REPO\"/3 should only contain the placeholder file.\n> >  test_expect_success 'directory empty from subsequent svn commit' '\n> > -     test -f \"$GIT_REPO\"/2/.gitignore &&\n> > +     test_path_is_file \"$GIT_REPO\"/2/.gitignore &&\n> >       test $(find \"$GIT_REPO\"/2 -type f | wc -l) = \"1\" &&\n> > -     test -f \"$GIT_REPO\"/3/.gitignore &&\n> > +     test_path_is_file \"$GIT_REPO\"/3/.gitignore &&\n> >       test $(find \"$GIT_REPO\"/3 -type f | wc -l) = \"1\"\n> >  '\n> >\n> > @@ -77,7 +77,7 @@ test_expect_success 'directory empty from subsequent svn commit' '\n> >  # generated for every sub-directory at some point in the repo's history.\n> >  test_expect_success 'add entry to previously empty directory' '\n> >       test $(find \"$GIT_REPO\"/4 -type f | wc -l) = \"1\" &&\n> > -     test -f \"$GIT_REPO\"/4/a/b/c/foo\n> > +     test_path_is_file \"$GIT_REPO\"/4/a/b/c/foo\n> >  '\n> >\n> >  # The HEAD~2 commit should not have introduced .gitignore placeholder files.\n> > @@ -102,14 +102,14 @@ test_expect_success 'clone svn repo with --placeholder-file specified' '\n> >\n> >  # \"$GIT_REPO\"/5/.placeholder should be a file, and non-empty.\n> >  test_expect_success 'placeholder namespace conflict with file' '\n> > -     test -s \"$GIT_REPO\"/5/.placeholder\n> > +     test_file_not_empty \"$GIT_REPO\"/5/.placeholder\n> >  '\n> >\n> >  # \"$GIT_REPO\"/6/.placeholder should be a directory, and the \"$GIT_REPO\"/6 tree\n> >  # should only contain one file: the placeholder.\n> >  test_expect_success 'placeholder namespace conflict with directory' '\n> > -     test -d \"$GIT_REPO\"/6/.placeholder &&\n> > -     test -f \"$GIT_REPO\"/6/.placeholder/.placeholder &&\n> > +     test_path_is_dir \"$GIT_REPO\"/6/.placeholder &&\n> > +     test_path_is_file \"$GIT_REPO\"/6/.placeholder/.placeholder &&\n> >       test $(find \"$GIT_REPO\"/6 -type f | wc -l) = \"1\"\n> >  '\n> >\n> > @@ -133,19 +133,19 @@ test_expect_success 'second set of svn commits and rebase' '\n> >\n> >  # Check that --preserve-empty-dirs and --placeholder-file flag state\n> >  # stays persistent over multiple invocations.\n> > -test_expect_success 'flag persistence during subsqeuent rebase' '\n> > -     test -f \"$GIT_REPO\"/7/.placeholder &&\n> > +test_expect_success 'flag persistence during subsequent rebase' '\n> > +     test_path_is_file \"$GIT_REPO\"/7/.placeholder &&\n> >       test $(find \"$GIT_REPO\"/7 -type f | wc -l) = \"1\"\n> >  '\n> >\n> >  # Check that placeholder files are properly removed when unnecessary,\n> >  # even across multiple invocations.\n> > -test_expect_success 'placeholder list persistence during subsqeuent rebase' '\n> > -     test -f \"$GIT_REPO\"/1/file1.txt &&\n> > +test_expect_success 'placeholder list persistence during subsequent rebase' '\n> > +     test_path_is_file \"$GIT_REPO\"/1/file1.txt &&\n> >       test $(find \"$GIT_REPO\"/1 -type f | wc -l) = \"1\" &&\n> >\n> > -     test -f \"$GIT_REPO\"/5/file1.txt &&\n> > -     test -f \"$GIT_REPO\"/5/.placeholder &&\n> > +     test_path_is_file \"$GIT_REPO\"/5/file1.txt &&\n> > +     test_path_is_file \"$GIT_REPO\"/5/.placeholder &&\n> >       test $(find \"$GIT_REPO\"/5 -type f | wc -l) = \"2\"\n> >  '\n"}]}