t9160: use test_path_is_missing()
The test_must_fail() function should only be used for git commands since we assume that external commands work sanely. Since, not only should this file not exist, but there shouldn't exit _any_ filesystem entity in these paths, replace `test_must_fail test -f` with `test_path_is_missing`. Signed-off-by: Denton Liu <liu.denton@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Denton Liu committed
Apr 20, 2020 at 04:54 UTC
5c65897d2b591f1d023a52c93c729c2b5a90a2df
1 file changed
+2
-2
t/t9160-git-svn-preserve-empty-dirs.sh
+2
-2
@@ -86,8 +86,8 @@ test_expect_success 'remove non-last entry from directory' '
86
cd "$GIT_REPO" &&
87
git checkout HEAD~2
88
) &&
89
- test_must_fail test -f "$GIT_REPO"/2/.gitignore &&
90
- test_must_fail test -f "$GIT_REPO"/3/.gitignore
89
+ test_path_is_missing "$GIT_REPO"/2/.gitignore &&
90
+ test_path_is_missing "$GIT_REPO"/3/.gitignore
91
'
92
93
# After re-cloning the repository with --placeholder-file specified, there