diff options
author | COGONI Guillaume <cogoni.guillaume@gmail.com> | 2022-02-23 00:54:28 +0300 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2022-02-24 02:08:44 +0300 |
commit | f01f948282d00b0e22ff08a3acf859fd49bff07c (patch) | |
tree | 33ef9e1bea1cc4e8c47275abb24d3db7635d4d37 /t/t3903-stash.sh | |
parent | 2b9c1209706bc2ef0ab09fb0bdc7d405e225ce8b (diff) |
t/t3903-stash.sh: replace test [-d|-f] with test_path_is_*
Use test_path_is_* to replace test [-d|-f] because that give more
explicit debugging information. And it doesn't change the semantics.
Signed-off-by: COGONI Guillaume <cogoni.guillaume@gmail.com>
Co-authored-by: BRESSAT Jonathan <git.jonathan.bressat@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t3903-stash.sh')
-rwxr-xr-x | t/t3903-stash.sh | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/t/t3903-stash.sh b/t/t3903-stash.sh index 686747e55a..d6a37692f6 100755 --- a/t/t3903-stash.sh +++ b/t/t3903-stash.sh @@ -487,7 +487,7 @@ test_expect_failure 'stash directory to file' ' rm -fr dir && echo bar >dir && git stash save "directory to file" && - test -d dir && + test_path_is_dir dir && test foo = "$(cat dir/file)" && test_must_fail git stash apply && test bar = "$(cat dir)" && @@ -500,10 +500,10 @@ test_expect_failure 'stash file to directory' ' mkdir file && echo foo >file/file && git stash save "file to directory" && - test -f file && + test_path_is_file file && test bar = "$(cat file)" && git stash apply && - test -f file/file && + test_path_is_file file/file && test foo = "$(cat file/file)" ' |