Skip to content

Commit

Permalink
Test to cover RT #126842
Browse files Browse the repository at this point in the history
  • Loading branch information
jnthn committed Sep 15, 2017
1 parent e5c50ae commit 82a1e10
Showing 1 changed file with 19 additions and 1 deletion.
20 changes: 19 additions & 1 deletion S17-supply/syntax.t
@@ -1,7 +1,7 @@
use v6;
use Test;

plan 73;
plan 74;

{
my $s = supply {
Expand Down Expand Up @@ -579,4 +579,22 @@ subtest 'next in whenever' => {
ok $closed, 'Supply is closed by Supply block after it sends done';
}

# RT #126842
lives-ok {
for ^500 {
my $channel = Channel.new;
my $p1 = start {
react {
whenever $channel {
}
}
}
my $p2 = start {
$channel.send($_) for (1..10);
$channel.close;
}
await $p1,$p2;
}
}, 'No hang or crash using react to consume channels';

# vim: ft=perl6 expandtab sw=4

0 comments on commit 82a1e10

Please sign in to comment.