This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Upgrade to Filter::Simple 0.82
[perl5.git] / lib / Filter / Simple / t / filter_only.t
index e537609..2fc425b 100644 (file)
@@ -1,11 +1,16 @@
 BEGIN {
-    if ($ENV{PERL_CORE}) {
-        chdir('t') if -d 't';
-       @INC = qw(lib/Filter/Simple ../lib);
+    if( $ENV{PERL_CORE} ) {
+        chdir 't';
+        @INC = '../lib';
+    }
+    else {
+        unshift @INC, 't/lib/';
     }
 }
+chdir 't';
 
-use FilterOnlyTest qr/not ok/ => "ok", "bad" => "ok", fail => "die";
+use Filter::Simple::FilterOnlyTest qr/not ok/ => "ok", 
+                                   "bad" => "ok", fail => "die";
 print "1..9\n";
 
 sub fail { print "ok ", $_[0], "\n" }
@@ -22,7 +27,7 @@ print "ok 5\n";
 
 ok 7 unless not ok 6;
 
-no FilterOnlyTest; # THE FUN STOPS HERE
+no Filter::Simple::FilterOnlyTest; # THE FUN STOPS HERE
 
 print "not " unless "not ok" =~ /^not /;
 print "ok 8\n";