summaryrefslogtreecommitdiff
path: root/ext/Opcode/t
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2010-12-17 11:07:32 +0000
committerNicholas Clark <nick@ccl4.org>2010-12-17 11:07:32 +0000
commit9f29e3f6d14d9ef296bdd0950d86b1a4386f0e88 (patch)
tree1d97bc4ba84b62d29753a20e159f010e908370c3 /ext/Opcode/t
parentbd29e8c290c68f4fe50b5be99aefebc44ca79b37 (diff)
downloadperl-9f29e3f6d14d9ef296bdd0950d86b1a4386f0e88.tar.gz
Convert ext/Opcode/t/ops.t to Test::More
Diffstat (limited to 'ext/Opcode/t')
-rw-r--r--ext/Opcode/t/ops.t12
1 files changed, 5 insertions, 7 deletions
diff --git a/ext/Opcode/t/ops.t b/ext/Opcode/t/ops.t
index 30edcdaa5f..3f1c4277f0 100644
--- a/ext/Opcode/t/ops.t
+++ b/ext/Opcode/t/ops.t
@@ -8,20 +8,18 @@ BEGIN {
}
}
-print "1..2\n";
+use Test::More tests => 2;
eval <<'EOP';
- no ops 'fileno'; # equiv to "perl -M-ops=fileno"
+ no ops 'fileno';
$a = fileno STDIN;
EOP
-print $@ =~ /trapped/ ? "ok 1\n" : "not ok 1\n# $@\n";
+like($@, qr/trapped/, 'equiv to "perl -M-ops=fileno"');
eval <<'EOP';
- use ops ':default'; # equiv to "perl -M(as above) -Mops=:default"
+ use ops ':default';
eval 1;
EOP
-print $@ =~ /trapped/ ? "ok 2\n" : "not ok 2\n# $@\n";
-
-1;
+like($@, qr/trapped/, 'equiv to "perl -Mops=:default"');