Skip to content

Commit 71ce42c

Browse files
avargitster
authored andcommitted
test-lib: Print missing prerequisites in test output
Change the test output to print needed prerequisites as part of the TAP. This makes it easy to see at a glance why a test was skipped. Before: ok 7 # skip <message> ok 9 # skip <message> After: ok 7 # skip <message> (prereqs: DONTHAVEIT) ok 9 # skip <message> (prereqs: HAVEIT,DONTHAVEIT) This'll also be useful for smoke testing output, where the developer reading the output may not be familiar with the system where tests are being skipped. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
1 parent 93a5724 commit 71ce42c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

t/test-lib.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -403,7 +403,7 @@ test_skip () {
403403
case "$to_skip" in
404404
t)
405405
say_color skip >&3 "skipping test: $@"
406-
say_color skip "ok $test_count # skip $1"
406+
say_color skip "ok $test_count # skip $1 (prereqs: $prereq)"
407407
: true
408408
;;
409409
*)

0 commit comments

Comments
 (0)