Skip to content

Conversation

@chdanielmueller
Copy link

@chdanielmueller chdanielmueller commented Sep 23, 2025

This pull request introduces a new configuration option to control console output for failed tests in the silent reporter, along with updates to the documentation and logic for handling console logs.

New feature: Console logs on test failure

  • Added a new showConsoleOnFailure option to the silent reporter, allowing all console logs to be displayed for failed tests when enabled. This can be configured via reporter options or the JEST_SILENT_REPORTER_SHOW_CONSOLE_ON_FAILURE environment variable.

Reporter logic improvements

  • Updated the logic in SilentReporter.js so that when showConsoleOnFailure is enabled and a test fails, all console logs are shown for that test; otherwise, only warnings and errors are shown if showWarnings is enabled.

closes #40

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Output log output on failed tests

1 participant