Refactor t/run/switchn.t to use test.pl instead of making TAP by hand.
authorColin Kuskie <colink@perldreamer.com>
Sat, 15 Sep 2012 07:42:36 +0000 (00:42 -0700)
committerjkeenan <jkeenan@cpan.org>
Sun, 16 Sep 2012 16:40:26 +0000 (12:40 -0400)
t/run/switchn.t

index bca9a66..6ad4a72 100644 (file)
@@ -1,15 +1,19 @@
 #!./perl -n
 
 BEGIN {
-    print "1..3\n";
+    chdir 't' if -d 't';
+    @INC = '../lib';
+    require './test.pl';
     *ARGV = *DATA;
+    plan(tests => 3);
 }
 
 END {
-    print "ok 3\n";
+    pass("Final test");
 }
 
-print;
+chomp;
+is("ok ".$., $_, "Checking line $.");
 
 s/^/not /;