Subject: | Text-RecordParser 1.1.2, win32, test failure on missing optional prereq, t\10-tablify.t, patch |
The same problem in rt ticket 17788 has cropped up again:
The number of tests to skip has crept out-of-sync with the total no. of
tests.
If Text::TabularDisplay isn't installed, the no. of tests to skip is wrong.
The following patch will ensure that the number to skip is always correct.
(It might also be worth applying the same logic to 11-tabmerge.t, so the
same thing doesn't happen there too).
@@ -4,5 +4,7 @@
use Config;
use FindBin qw( $Bin );
-use Test::More tests => 13;
+our $test_count;
+BEGIN { $test_count = 13 };
+use Test::More tests => $test_count;
use Readonly;
use File::Spec::Functions;
@@ -18,5 +20,5 @@
if ($@) {
- skip 'Text::TabularDisplay not installed', 11;
+ skip 'Text::TabularDisplay not installed', $test_count-1;
}