Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[bug] I suspect the --failOnConsole parameter doesn't work any more. #410

Open
work933k opened this issue Nov 29, 2023 · 2 comments
Open

Comments

@work933k
Copy link
Contributor

work933k commented Nov 29, 2023

Describe the bug
I run test-storybook with the --failOnConsole parameter, but the tests pass even while there are errors in the browser-console.

To Reproduce
test-storybook --url http://localhost:6006 --index-json --failOnConsole --config-dir libs/dummy-app/shared/choose-product-date/.storybook

@storybook/test-runner@0.16.0

Output

Running command: test-storybook --url http://localhost:6006 --index-json --failOnConsole   --config-dir libs/dummy-app/shared/choose-product-date/.storybook
Serving "dist/storybook/dummy-app-shared-choose-product-date" at "http://localhost:6006/"
[test-storybook] Cleaning up /tmp/86f0791b657a5727a17427b83e310a61
 PASS   browser: chromium  ../../tmp/86f0791b657a5727a17427b83e310a61/pensionpostponecomponent.test.js
 PASS   browser: chromium  ../../tmp/86f0791b657a5727a17427b83e310a61/participationdetailcomponent.test.js
 PASS   browser: chromium  ../../tmp/86f0791b657a5727a17427b83e310a61/pensionbringforwardcomponent.test.js
 PASS   browser: chromium  ../../tmp/86f0791b657a5727a17427b83e310a61/choosepensiondatecomponent.test.js
 PASS   browser: chromium  ../../tmp/86f0791b657a5727a17427b83e310a61/participationapplychoicescomponent.test.js

Test Suites: 5 passed, 5 total
Tests:       5 passed, 5 total
Snapshots:   0 total
Time:        5.682 s
Ran all test suites.

It used to work before.

@matttk
Copy link

matttk commented Nov 30, 2023

We also ran into this yesterday. Tried console.log in various places and it never works anywhere.

@yannbf
Copy link
Member

yannbf commented Dec 1, 2023

Hey there @matttk @work933k could you provide a reproduction? I just tested the flag in two different projects and it works as intended. The flag is only intended to fail on console.error calls during the rendering or play function, btw.

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

No branches or pull requests

3 participants