redux-saga-test-plan icon indicating copy to clipboard operation
redux-saga-test-plan copied to clipboard

Failing tests cannot console.log

Open slpixe opened this issue 7 years ago • 2 comments
trafficstars

I have a test which is using expectSaga, the saga gets called, but if the test fails, it doesn't output any console.log which was within the saga.

If the test passes, console.log within the saga are output

slpixe avatar Jan 10 '18 11:01 slpixe

Hi @slpixe. Can you provide a test case with this behavior? Also, which test runner and Node version are you using?

jfairbank avatar Feb 06 '18 13:02 jfairbank

I experience similar issue. But in my case the console.log doesn't get shown even in the successful test.

v16.14.2 "jest": "~27.3.1",

EDIT: In my case I didn't await nor return the expectSaga so the test completed before the console.log() get a chance to run.

croraf avatar Apr 26 '22 17:04 croraf