summaryrefslogtreecommitdiffstats
path: root/t/t4013/diff.format-patch_--inline_--stdout_initial..master^
diff options
context:
space:
mode:
authorPatrick Steinhardt <ps@pks.im>2026-04-21 09:34:25 +0200
committerJunio C Hamano <gitster@pobox.com>2026-04-22 15:53:36 -0700
commitffe8005b9d8e0cf1b5d5d796ca4da76fbe219011 (patch)
tree3c292b606d73f6dc1812c6f1c38757a28c8c2409 /t/t4013/diff.format-patch_--inline_--stdout_initial..master^
parent1ecf6538263cf81c151f2e720cd73fde3d50a07e (diff)
downloadgit-ffe8005b9d8e0cf1b5d5d796ca4da76fbe219011.tar.gz
git-ffe8005b9d8e0cf1b5d5d796ca4da76fbe219011.zip
t: detect errors outside of test cases
We have recently merged a patch series that had a simple misspelling of `test_expect_success`. Instead of making our tests fail though, this typo went completely undetected and all of our tests passed, which is of course unfortunate. This is a more general issue with our test suite: all commands that run outside of a specific test case can fail, and if we don't explicitly check for such failure then this failure will be silently ignored. Improve the status quo by enabling the errexit option so that any such unchecked failures will cause us to abort immediately. Note that for now, we only enable this option for Bash 5 and newer. This is because other shells have wildly different behaviour, and older versions of Bash (especially on macOS) are buggy. The list of enabled shells may be extended going forward. Helped-by: Jeff King <peff@peff.net> Signed-off-by: Patrick Steinhardt <ps@pks.im> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t4013/diff.format-patch_--inline_--stdout_initial..master^')
0 files changed, 0 insertions, 0 deletions