Skip to content

Commit e8fd9ec

Browse files
committed
Add tests for RT #116096
1 parent 054665c commit e8fd9ec

File tree

1 file changed

+10
-1
lines changed

1 file changed

+10
-1
lines changed

S02-types/set.t

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
use v6;
22
use Test;
33

4-
plan 169;
4+
plan 173;
55

66
sub showset($s) { $s.keys.sort.join(' ') }
77

@@ -377,4 +377,13 @@ dies_ok { set(1, 2) «+» set(3, 4) }, 'Set «+» Set is illegal';
377377
'Faulty .WHICH creation';
378378
}
379379

380+
# RT #116096
381+
{
382+
my $s = Set.new([1,2],[3,4]);
383+
is $s.elems, 2, 'arrays not flattened out by Set.new (1)';
384+
ok $s.keys[0] eqv any([1,2], [3,4]), 'arrays not flattened out by Set.new (2)';
385+
ok $s.keys[1] eqv any([1,2], [3,4]), 'arrays not flattened out by Set.new (3)';
386+
nok $s.keys[0] eqv $s.keys[1], 'arrays not flattened out by Set.new (4)';
387+
}
388+
380389
# vim: ft=perl6

0 commit comments

Comments
 (0)