# Pastebin 02Zcq1m7 { class TestOnDemandSupply does Tappable { method tap(&emit, &, &, &tap) { my $t = $*SCHEDULER.cue({.&emit for ^4}); tap($t); $t } method sane\ (--> True) {} method serial\ (--> False) {} method live\ (--> False) {} } subtest { react { whenever Promise.in(10) { flunk "zip timed out"; done; } whenever Supply.zip: Supply.from-list(^2), Supply.new(TestOnDemandSupply.new) -> $l { .say; if $l eqv ((0, 0) | (1, 1)) { pass "zip is ok" } else { flunk "invalid value: $l" } LAST { done } } } } }