summaryrefslogtreecommitdiffstats
path: root/gnu/usr.bin/perl/t/run/switchM.t
diff options
context:
space:
mode:
authorafresh1 <afresh1@openbsd.org>2014-03-24 14:58:42 +0000
committerafresh1 <afresh1@openbsd.org>2014-03-24 14:58:42 +0000
commit91f110e064cd7c194e59e019b83bb7496c1c84d4 (patch)
tree3e8e577405dba7e94b43cbf21c22f21aaa5ab949 /gnu/usr.bin/perl/t/run/switchM.t
parentdo not call purge_task every 10 secs, it is only needed once at startup and (diff)
downloadwireguard-openbsd-91f110e064cd7c194e59e019b83bb7496c1c84d4.tar.xz
wireguard-openbsd-91f110e064cd7c194e59e019b83bb7496c1c84d4.zip
Import perl-5.18.2
OK espie@ sthen@ deraadt@
Diffstat (limited to 'gnu/usr.bin/perl/t/run/switchM.t')
-rw-r--r--gnu/usr.bin/perl/t/run/switchM.t19
1 files changed, 19 insertions, 0 deletions
diff --git a/gnu/usr.bin/perl/t/run/switchM.t b/gnu/usr.bin/perl/t/run/switchM.t
new file mode 100644
index 00000000000..72e8908b01b
--- /dev/null
+++ b/gnu/usr.bin/perl/t/run/switchM.t
@@ -0,0 +1,19 @@
+#!./perl
+
+BEGIN {
+ chdir 't' if -d 't';
+ @INC = '../lib';
+}
+use strict;
+
+require './test.pl';
+
+plan(2);
+
+like(runperl(switches => ['-Irun/flib', '-Mbroken'], stderr => 1),
+ qr/^Global symbol "\$x" requires explicit package name at run\/flib\/broken.pm line 6\./,
+ "Ensure -Irun/flib produces correct filename in warnings");
+
+like(runperl(switches => ['-Irun/flib/', '-Mbroken'], stderr => 1),
+ qr/^Global symbol "\$x" requires explicit package name at run\/flib\/broken.pm line 6\./,
+ "Ensure -Irun/flib/ produces correct filename in warnings");