Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
branch: master
Fetching contributors…

Octocat-spinner-32-eaf2f5

Cannot retrieve contributors at this time

file 17 lines (13 sloc) 0.356 kb
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
use v6;
use Test;
plan 4;

#L<S03/"Smart matching"/Regex Hash hash key grep>
{
    my %h = (moep => 'foo', bar => 'baz');
    ok (/oep/ ~~ %h), 'Regex ~~ Hash (+,1)';
    ok (/bar/ ~~ %h), 'Regex ~~ Hash (+,2)';
    ok !(/ugh/ ~~ %h), 'Regex ~~ Hash (-,1)';
    ok !(/foo/ ~~ %h), 'Regex ~~ Hash (-,value)';
}

done;

# vim: ft=perl6
Something went wrong with that request. Please try again.