Change the regression test added by 26410 to use test.pl; this makes
[p5sagit/p5-mst-13.2.git] / t / op / mydef.t
index f089c31..f250ff6 100644 (file)
@@ -1,11 +1,11 @@
-#!./perl -w
+#!./perl
 
 BEGIN {
     chdir 't' if -d 't';
     @INC = '../lib';
 }
 
-print "1..66\n";
+print "1..70\n";
 
 my $test = 0;
 sub ok ($$) {
@@ -189,3 +189,12 @@ END { unlink $file; }
     ok( $x eq "hello\n", 'reading from <$_> works' );
     close $_;
 }
+
+{
+    $fqdb::_ = 'fqdb';
+    ok( $fqdb::_ eq 'fqdb', 'fully qualified $_ is not in main' );
+    ok( eval q/$fqdb::_/ eq 'fqdb', 'fully qualified, evaled $_ is not in main' );
+    package fqdb;
+    ::ok( $_ ne 'fqdb', 'unqualified $_ is in main' );
+    ::ok( q/$_/ ne 'fqdb', 'unqualified, evaled $_ is in main' );
+}