t3905: replace test -s with test_file_not_empty

In order to modernize the test script, replace `test -s` with test_file_not_empty(), which provides better diagnostic output in the case of failure. Signed-off-by: Denton Liu <liu.denton@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Denton Liu committed Feb 8, 2021 at 23:28 UTC 27e25a8cbfff4a53eb1bf6bac8486af6a6a1201d
1 file changed +6 -6
t/t3905-stash-include-untracked.sh
+6 -6
@@ -169,9 +169,9 @@ test_expect_success 'stash save --include-untracked respects .gitignore' '
169 mkdir ignored.d &&
170 echo ignored >ignored.d/untracked &&
171 git stash -u &&
172 - test -s ignored &&
173 - test -s ignored.d/untracked &&
174 - test -s .gitignore
172 + test_file_not_empty ignored &&
173 + test_file_not_empty ignored.d/untracked &&
174 + test_file_not_empty .gitignore
175 '
176
177 test_expect_success 'stash save -u can stash with only untracked files different' '
@@ -189,9 +189,9 @@ test_expect_success 'stash save --all does not respect .gitignore' '
189
190 test_expect_success 'stash save --all is stash poppable' '
191 git stash pop &&
192 - test -s ignored &&
193 - test -s ignored.d/untracked &&
194 - test -s .gitignore
192 + test_file_not_empty ignored &&
193 + test_file_not_empty ignored.d/untracked &&
194 + test_file_not_empty .gitignore
195 '
196
197 test_expect_success 'stash push --include-untracked with pathspec' '