diff options
author | Nicholas Clark <nick@ccl4.org> | 2005-01-28 13:59:40 +0000 |
---|---|---|
committer | Nicholas Clark <nick@ccl4.org> | 2005-01-28 13:59:40 +0000 |
commit | b37cb8219ff2bec6842038e1ec5cb9efeb4c223a (patch) | |
tree | 690f2f4dff50bc5eef741db4e8a41d935af8159b /ext/B | |
parent | e4fd38941528df23061370b7dfaa954d8f9c6685 (diff) | |
download | perl-b37cb8219ff2bec6842038e1ec5cb9efeb4c223a.tar.gz |
Calculate the number of tests in one place, so that the skip()s will
always agree with the plan()s
p4raw-id: //depot/perl@23894
Diffstat (limited to 'ext/B')
-rw-r--r-- | ext/B/t/optree_check.t | 5 | ||||
-rw-r--r-- | ext/B/t/optree_concise.t | 5 |
2 files changed, 6 insertions, 4 deletions
diff --git a/ext/B/t/optree_check.t b/ext/B/t/optree_check.t index 03ccbcb58f..ee682fde50 100644 --- a/ext/B/t/optree_check.t +++ b/ext/B/t/optree_check.t @@ -29,10 +29,11 @@ cmdline args in 'standard' way across all clients of OptreeCheck. =cut -plan tests => 5 + 15 + 16 * $gOpts{selftest}; # pass()s + $#tests +my $tests = 5 + 15 + 16 * $gOpts{selftest}; # pass()s + $#tests +plan tests => $tests; SKIP: { - skip "no perlio in this build", 5 + 17 + 14 * $gOpts{selftest} + skip "no perlio in this build", $tests unless $Config::Config{useperlio}; diff --git a/ext/B/t/optree_concise.t b/ext/B/t/optree_concise.t index b839fb86c9..b14af0da45 100644 --- a/ext/B/t/optree_concise.t +++ b/ext/B/t/optree_concise.t @@ -20,9 +20,10 @@ BEGIN { use OptreeCheck; # ALSO DOES @ARGV HANDLING !!!!!! use Config; -plan tests => 23; +my $tests = 23; +plan tests => $tests; SKIP: { -skip "no perlio in this build", 24 unless $Config::Config{useperlio}; +skip "no perlio in this build", $tests unless $Config::Config{useperlio}; $SIG{__WARN__} = sub { my $err = shift; |