Skip to content

Commit 536a9ce

Browse files
avargitster
authored andcommitted
fsck tests: add a test for no skipList input
The recent 65a836f ("fsck: add stress tests for fsck.skipList", 2018-07-27) added various stress tests for odd invocations of fsck.skipList, but didn't tests for some very simple ones, such as asserting that providing to skipList with a bad commit causes fsck to exit with a non-zero exit code. Add such a test. Signed-off-by: Ævar Arnfjörð Bjarmason <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 134b732 commit 536a9ce

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

t/t5504-fetch-receive-strict.sh

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -137,6 +137,11 @@ test_expect_success 'setup bogus commit' '
137137
commit="$(git hash-object -t commit -w --stdin <bogus-commit)"
138138
'
139139

140+
test_expect_success 'fsck with no skipList input' '
141+
test_must_fail git fsck 2>err &&
142+
test_i18ngrep "missingEmail" err
143+
'
144+
140145
test_expect_success 'fsck with invalid or bogus skipList input' '
141146
git -c fsck.skipList=/dev/null -c fsck.missingEmail=ignore fsck &&
142147
test_must_fail git -c fsck.skipList=does-not-exist -c fsck.missingEmail=ignore fsck 2>err &&

0 commit comments

Comments
 (0)