1 use Test::Base tests => 3;
6 tie_output(*STDOUT, $out);
7 tie_output(*STDERR, $err);
11 print "The eagle has landed\n";
13 is $out, "Stuff\nThe eagle has landed\n";
15 print "This bird had flown\n";
17 is $out, "Stuff\nThe eagle has landed\nThis bird had flown\n";
19 print STDERR "You 'lil rascal...\n";
21 is $err, "Keep out!\nYou 'lil rascal...\n";