Open szpytfire opened 3 months ago
@szpytfire You need to add it to your story parameters, see: https://github.com/storybookjs/storybook/blob/a17fe0bc0cd13e702995501834674dfd9ee77aec/code/lib/preview-api/src/modules/preview-web/render/StoryRender.ts#L242-L243
Hey @jaknas - yep, thanks 🙏 I found this in the end after snooping around the storybook code 😄!
I wonder whether to help future users:
dangerouslyIgnoreUnhandledErrors
should be enabled at a global level (so that you don't have to set it on lots of individual stories)
Describe the bug
A couple of my interaction tests are failing due to Unhandled Errors caused by an upstream dependency I'm using.
The output of the interaction test kindly suggests the following:
After reading this, I tried adding the following snippet into my
.storybook/main.ts
configuration:However, the exception is still thrown (and the interaction test still states that I need to set the
test.dangerouslyIgnoreUnhandledErrors
param).Is this expected? Are parameters passed through to vitest?
To Reproduce
-
System
Additional context
Relates to: https://github.com/xyflow/xyflow/issues/2461