Permalink
Browse files

[t/spec] Tests for RT #70007

git-svn-id: http://svn.pugscode.org/pugs@28900 c213334d-75ef-0310-aa23-eaa082d1ae64
  • Loading branch information...
1 parent 819d1c6 commit b54c647633213e998eb9d217322627693293e84a kyle committed Oct 26, 2009
Showing with 16 additions and 3 deletions.
  1. +16 −3 S05-match/capturing-contexts.t
@@ -1,8 +1,8 @@
use v6;
-
use Test;
-
-plan 21;
+BEGIN { @*INC.push('t/spec/packages/') };
+use Test::Util;
+plan *;
if !eval('("a" ~~ /a/)') {
skip_rest "skipped tests - rules support appears to be missing";
@@ -81,4 +81,17 @@ if !eval('("a" ~~ /a/)') {
'Match coerced to Hash says match exists';
}
+#?rakudo skip 'RT 70007'
+nok 'aa' ~~ /(.)$1/, 'match with non-existent capture does not match';
+#?rakudo todo 'RT 70007'
+is_run( q{'aa' ~~ /(.)$1/},
+ {
+ status => 0,
+ out => '',
+ err => rx/\S/,
+ },
+ 'match with non-existent capture emits a warning' );
+
+done_testing;
+
# vim: ft=perl6

0 comments on commit b54c647

Please sign in to comment.