Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Test Channel.closed without .receive
  • Loading branch information
moritz committed Feb 7, 2015
1 parent 4dca70c commit 0f7192a
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion S17-channel/basic.t
@@ -1,7 +1,7 @@
use v6;
use Test;

plan 15;
plan 16;

{
my Channel $c .= new;
Expand Down Expand Up @@ -49,3 +49,10 @@ plan 15;
my $p = Supply.for(1..5);
is ~@($p.Channel), "1 2 3 4 5", "Supply.for and @(.Channel) work";
}

{
my $c = Channel.new;
$c.close;
is $c.closed.status, Kept, 'Closing a channel immediately keeps its .closed promise';

}

0 comments on commit 0f7192a

Please sign in to comment.