jest: console.error/warn/log should show on `jest --watch` output

Currently, jest --watch output won’t include console.error/warn/log, which can lead to things silently failing.

One simple use case is a Promise making an HTTP request, handling exceptions but also logging to console.error to alert the developer. If an HTTP request is failing is because I probably forgot to mock something, but instead it will just silently output nothing.

About this issue

  • Original URL
  • State: closed
  • Created 8 years ago
  • Comments: 17 (7 by maintainers)

Most upvoted comments

Add ‘silent’ value in your package.json scripts config. This solves the issue on my side. Using Jest version 19.0.0. Like: Before: “test”: “jest --colors”, After: “test”: “jest --silent=false --colors”,

@davidaurelio upgrade to Jest v18.1, this should be fixed there for Node 7

I’m seeing this issue on Node 7. Downgrading to Node 6 fixes it.

If you are using Jest 15 it should definitely be printed unless you also add --silent or something else is happening.

Can you please provide more information? The issue template is there for a reason 😉 Which OS are you on, which version of node, which version of Jest, etc.?