Closed fernandogmar closed 1 year ago
Promises are async always so you're going to get different results compared to constant
which is sync.
Thanks! then I am missing an async version for testing streams with promises 😅 ...anyway, I have already got a different approach using directly sinon. Thanks again!
No problem, I don't think the built in test tooling handles actual async particularly well. It sort of pretends to handle async with the parseDiagram
and underlying clock mocking but if you need to use an actual promise, you'll need to deal with that in the test.
Hi!
just trying to test a stream that contains a
fromPromise
call, it does not give me the expected results. But if we would replace it withconstant
it works fine. Below an example: