more better tests
[p5sagit/Function-Parameters.git] / t / eating_strict_error.t
CommitLineData
5bf140a1 1#!perl
2
3use Test::More tests => 2;
4
5use warnings FATAL => 'all';
6use strict;
7
8use Dir::Self;
9
10#use Test::Fatal;
11
12my $file = __DIR__ . "/eating_strict_error.fail";
13my $done = do $file;
14my $exc = $@;
15my $err = $!;
16
17is $done, undef, "faulty code doesn't load";
18is $exc, qq{Global symbol "\$records" requires explicit package name at $file line 5.\nBEGIN not safe after errors--compilation aborted at $file line 9.\n};
19$exc or die "$file: $err";