From: Rafael Garcia-Suarez Date: Sun, 30 Aug 2009 13:54:31 +0000 (+0200) Subject: Remove test boilerplate from Safe tests X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=54f12473d1fe441ffe03a5bc36063c25ad72685f;p=p5sagit%2Fp5-mst-13.2.git Remove test boilerplate from Safe tests (except safeops.t, which needs to have the perl sources available, so it must be skipped when run from the CPAN distribution. However it's currently skipped under a core build too.) --- diff --git a/ext/Safe/t/safe1.t b/ext/Safe/t/safe1.t index 6a3b908..385d661 100644 --- a/ext/Safe/t/safe1.t +++ b/ext/Safe/t/safe1.t @@ -1,10 +1,6 @@ #!./perl -w $|=1; BEGIN { - if($ENV{PERL_CORE}) { - chdir 't' if -d 't'; - @INC = '../lib'; - } require Config; import Config; if ($Config{'extensions'} !~ /\bOpcode\b/ && $Config{'osname'} ne 'VMS') { print "1..0\n"; diff --git a/ext/Safe/t/safe2.t b/ext/Safe/t/safe2.t index d0239d1..2548dcc 100644 --- a/ext/Safe/t/safe2.t +++ b/ext/Safe/t/safe2.t @@ -1,10 +1,6 @@ #!./perl -w $|=1; BEGIN { - if($ENV{PERL_CORE}) { - chdir 't' if -d 't'; - @INC = '../lib'; - } require Config; import Config; if ($Config{'extensions'} !~ /\bOpcode\b/ && $Config{'osname'} ne 'VMS') { print "1..0\n"; diff --git a/ext/Safe/t/safe3.t b/ext/Safe/t/safe3.t index c809f27..1f99f49 100644 --- a/ext/Safe/t/safe3.t +++ b/ext/Safe/t/safe3.t @@ -1,10 +1,6 @@ #!perl -w BEGIN { - if ($ENV{PERL_CORE}) { - chdir 't' if -d 't'; - @INC = '../lib'; - } require Config; import Config; if ($Config{'extensions'} !~ /\bOpcode\b/ && $Config{'extensions'} !~ /\bPOSIX\b/ diff --git a/ext/Safe/t/safeload.t b/ext/Safe/t/safeload.t index b15c290..2d2c3cc 100644 --- a/ext/Safe/t/safeload.t +++ b/ext/Safe/t/safeload.t @@ -1,10 +1,6 @@ #!perl BEGIN { - if ($ENV{PERL_CORE}) { - chdir 't' if -d 't'; - @INC = '../lib'; - } require Config; import Config; if ($Config{'extensions'} !~ /\bOpcode\b/) { diff --git a/ext/Safe/t/safeops.t b/ext/Safe/t/safeops.t index 229672e..ee83ac8 100644 --- a/ext/Safe/t/safeops.t +++ b/ext/Safe/t/safeops.t @@ -8,7 +8,7 @@ BEGIN { } else { # this won't work outside of the core, so exit - print "1..0\n"; exit 0; + print "1..0 # skipped: PERL_CORE unset\n"; exit 0; } } use Config; diff --git a/ext/Safe/t/safeuniversal.t b/ext/Safe/t/safeuniversal.t index c6d9911..95867c5 100644 --- a/ext/Safe/t/safeuniversal.t +++ b/ext/Safe/t/safeuniversal.t @@ -1,10 +1,6 @@ #!perl BEGIN { - if ($ENV{PERL_CORE}) { - chdir 't' if -d 't'; - @INC = '../lib'; - } require Config; import Config; if ($Config{'extensions'} !~ /\bOpcode\b/) {