Browse Source

Merge branch 'ab/test-readme-updates'

Doc updates.

* ab/test-readme-updates:
  t/README: clarify the test_have_prereq documentation
  t/README: change "Inside <X> part" to "Inside the <X> part"
  t/README: link to metacpan.org, not search.cpan.org
maint
Junio C Hamano 8 years ago
parent
commit
de8a8ed155
  1. 12
      t/README

12
t/README

@ -471,13 +471,13 @@ Don't: @@ -471,13 +471,13 @@ Don't:
their output.

You can glean some further possible issues from the TAP grammar
(see http://search.cpan.org/perldoc?TAP::Parser::Grammar#TAP_Grammar)
(see https://metacpan.org/pod/TAP::Parser::Grammar#TAP-GRAMMAR)
but the best indication is to just run the tests with prove(1),
it'll complain if anything is amiss.

Keep in mind:

- Inside <script> part, the standard output and standard error
- Inside the <script> part, the standard output and standard error
streams are discarded, and the test harness only reports "ok" or
"not ok" to the end user running the tests. Under --verbose, they
are shown to help debugging the tests.
@ -611,9 +611,11 @@ library for your script to use. @@ -611,9 +611,11 @@ library for your script to use.

- test_have_prereq <prereq>

Check if we have a prerequisite previously set with
test_set_prereq. The most common use of this directly is to skip
all the tests if we don't have some essential prerequisite:
Check if we have a prerequisite previously set with test_set_prereq.
The most common way to use this explicitly (as opposed to the
implicit use when an argument is passed to test_expect_*) is to skip
all the tests at the start of the test script if we don't have some
essential prerequisite:

if ! test_have_prereq PERL
then

Loading…
Cancel
Save