diff options
Diffstat (limited to 't/op/pat.t')
-rwxr-xr-x | t/op/pat.t | 19 |
1 files changed, 18 insertions, 1 deletions
diff --git a/t/op/pat.t b/t/op/pat.t index 188a3a3b13..e00328c91f 100755 --- a/t/op/pat.t +++ b/t/op/pat.t @@ -4,7 +4,7 @@ # the format supported by op/regexp.t. If you want to add a test # that does fit that format, add it to op/re_tests, not here. -print "1..211\n"; +print "1..213\n"; BEGIN { chdir 't' if -d 't'; @@ -995,3 +995,20 @@ $test++; "\n\n" =~ /\n+ $ \n/x or print "not "; print "ok $test\n"; $test++; + +[] =~ /^ARRAY/ or print "# [] \nnot "; +print "ok $test\n"; +$test++; + +eval << 'EOE'; +{ + package S; + use overload '""' => sub { 'Object S' }; + sub new { bless [] } +} +$a = 'S'->new; +EOE + +$a and $a =~ /^Object\sS/ or print "# '$a' \nnot "; +print "ok $test\n"; +$test++; |