We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 76eac4d commit 397ddeeCopy full SHA for 397ddee
S17-supply/head.t
@@ -0,0 +1,18 @@
1
+use v6;
2
+use lib 't/spec/packages';
3
+
4
+use Test;
5
+use Test::Tap;
6
7
+plan 8;
8
9
+dies-ok { Supply.head }, 'can not be called as a class method';
10
+dies-ok { Supply.new.head("foo") }, 'cannot have "foo" head';
11
12
+for ThreadPoolScheduler.new, CurrentThreadScheduler -> $*SCHEDULER {
13
+ diag "**** scheduling with {$*SCHEDULER.WHAT.perl}";
14
15
+ tap-ok Supply.from-list(1..10).head, [1,], "head without argument works";
16
+ tap-ok Supply.from-list(1..10).head(5), [1..5], "head five works";
17
+ tap-ok Supply.from-list(1..10).head(15), [1..10], "head 15 works";
18
+}
0 commit comments