summaryrefslogtreecommitdiff
path: root/t/test.pl
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2011-03-07 13:33:48 +0000
committerNicholas Clark <nick@ccl4.org>2011-03-07 13:33:48 +0000
commite05e9c3d01e748834948a3f9f9f62c9e72295130 (patch)
treef644689e9b3c8ceef84dc973c3866bf1508abc94 /t/test.pl
parentb6ae43b72863e12dd1cfc7eb414a05d61a20d8bd (diff)
downloadperl-e05e9c3d01e748834948a3f9f9f62c9e72295130.tar.gz
Add skip_all_without_perlio() to test.pl, and use it in 8 tests.
It's a common idiom in the tests. This makes it easier to find, read, and remove.
Diffstat (limited to 't/test.pl')
-rw-r--r--t/test.pl4
1 files changed, 4 insertions, 0 deletions
diff --git a/t/test.pl b/t/test.pl
index 9958356285..a09c831cb4 100644
--- a/t/test.pl
+++ b/t/test.pl
@@ -132,6 +132,10 @@ sub skip_all_without_extension {
skip_all("$extension was not built");
}
+sub skip_all_without_perlio {
+ skip_all('no PerlIO') unless PerlIO::Layer->find('perlio');
+}
+
sub _ok {
my ($pass, $where, $name, @mess) = @_;
# Do not try to microoptimize by factoring out the "not ".