From c924057c56994f6738a6732ba782dfd2f6e5b969 Mon Sep 17 00:00:00 2001 From: alex Date: Wed, 26 Jan 2022 12:44:15 +0000 Subject: [PATCH] slowcat test --- test/pattern.test.mjs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/test/pattern.test.mjs b/test/pattern.test.mjs index f6e0d545..ddb2e981 100644 --- a/test/pattern.test.mjs +++ b/test/pattern.test.mjs @@ -109,4 +109,10 @@ describe('Pattern', function() { assert.deepStrictEqual(fastcat([pure("a"), pure("b")]).firstCycle.map(x => x.value), ["a", "b"]) }) }) + describe('slowcat()', function () { + it('Can concatenate things slowly', function () { + assert.deepStrictEqual(slowcat([pure("a"), pure("b")]).firstCycle.map(x => x.value), ["a"]) + assert.deepStrictEqual(slowcat([pure("a"), pure("b")])._early(1).firstCycle.map(x => x.value), ["b"]) + }) + }) }) \ No newline at end of file