From 0cd39adf63bbc345adf2626353dca017ce526563 Mon Sep 17 00:00:00 2001 From: Colin Kuskie Date: Sat, 15 Sep 2012 00:51:28 -0700 Subject: [PATCH] Refactor t/run/noswitch.t to use test.pl instead of making TAP by hand. --- t/run/noswitch.t | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/t/run/noswitch.t b/t/run/noswitch.t index a902c1f..ff56253 100644 --- a/t/run/noswitch.t +++ b/t/run/noswitch.t @@ -1,12 +1,16 @@ #!./perl BEGIN { - print "1..3\n"; + chdir 't' if -d 't'; + @INC = '../lib'; + require './test.pl'; *ARGV = *DATA; + plan(tests => 3); } -print "ok 1\n"; -print <>; -print "ok 3\n"; + +pass("first test"); +is( scalar <>, "ok 2\n", "read from aliased DATA filehandle"); +pass("last test"); __DATA__ -ok 2 - read from aliased DATA filehandle +ok 2 -- 2.7.4