Skip to content

Commit

Permalink
Extend tests for RT #117773
Browse files Browse the repository at this point in the history
  • Loading branch information
usev6 committed Oct 15, 2014
1 parent ef1a317 commit 9186415
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions S02-types/baghash.t
@@ -1,7 +1,7 @@
use v6;
use Test;

plan 250;
plan 252;

# L<S02/Mutable types/QuantHash of UInt>

Expand Down Expand Up @@ -554,6 +554,11 @@ sub showkv($x) {

# RT #117773
{
my $b = BagHash.new( (a=>"b") );
ok $b.keys[0] ~~ ("a" => "b"), 'first key of BagHash is a Pair ("a" => "b")';
my $b1 = BagHash.new( (a=>"b") );
ok $b1.keys[0] ~~ ("a" => "b"), 'first key of BagHash is a Pair ("a" => "b")';
my $b2 = BagHash.new( "a"=>"b" );
ok $b2.keys[0] ~~ ("a" => "b"), 'again first key of BagHash is a Pair ("a" => "b")';
my $b3 = BagHash.new( a=>"b" );
ok $b3.elems == 0,
'named argument is happily eaten by .new method';
}

0 comments on commit 9186415

Please sign in to comment.