summaryrefslogtreecommitdiff
path: root/t/README
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2018-02-27 18:33:58 (GMT)
committerJunio C Hamano <gitster@pobox.com>2018-02-27 18:33:58 (GMT)
commite3eb4050272e790ee9c7d9e08e44b34322387da6 (patch)
treeb85623c202d446d2dbcc01b2d5e55295e89dd861 /t/README
parent1ba6846a19b0358ddf4098d44ba5804646c36412 (diff)
parent12e31a6b12b0a8497f35b327219c348186e0a666 (diff)
downloadgit-e3eb4050272e790ee9c7d9e08e44b34322387da6.zip
git-e3eb4050272e790ee9c7d9e08e44b34322387da6.tar.gz
git-e3eb4050272e790ee9c7d9e08e44b34322387da6.tar.bz2
Merge branch 'sg/doc-test-must-fail-args'
Devdoc update. * sg/doc-test-must-fail-args: t: document 'test_must_fail ok=<signal-name>'
Diffstat (limited to 't/README')
-rw-r--r--t/README14
1 files changed, 12 insertions, 2 deletions
diff --git a/t/README b/t/README
index b3f7b44..1a1361a 100644
--- a/t/README
+++ b/t/README
@@ -655,7 +655,7 @@ library for your script to use.
test_expect_code 1 git merge "merge msg" B master
'
- - test_must_fail <git-command>
+ - test_must_fail [<options>] <git-command>
Run a git command and ensure it fails in a controlled way. Use
this instead of "! <git-command>". When git-command dies due to a
@@ -663,11 +663,21 @@ library for your script to use.
treats it as just another expected failure, which would let such a
bug go unnoticed.
- - test_might_fail <git-command>
+ Accepts the following options:
+
+ ok=<signal-name>[,<...>]:
+ Don't treat an exit caused by the given signal as error.
+ Multiple signals can be specified as a comma separated list.
+ Currently recognized signal names are: sigpipe, success.
+ (Don't use 'success', use 'test_might_fail' instead.)
+
+ - test_might_fail [<options>] <git-command>
Similar to test_must_fail, but tolerate success, too. Use this
instead of "<git-command> || :" to catch failures due to segv.
+ Accepts the same options as test_must_fail.
+
- test_cmp <expected> <actual>
Check whether the content of the <actual> file matches the