Does vitest run any default test for storybook stories? #32506
-
SummaryI don't have tests written using play for my stories. But when I run vitest, it passes with 1 test with the name as Default. What tests are they? Is it required? Additional informationNo response Create a reproductionNo response |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
|
Yes, when you use the Storybook Vitest addon, it automatically generates a default "smoke test" for each story—even if you haven't written any play functions or explicit tests. This test simply checks that your story renders without errors. If you see a single test named "Default" passing, that's this render test for your default story. It's not strictly required, but it provides a basic safety net to catch rendering issues early. You can configure which stories are tested or skip these if you want—see the official docs for details. To reply, just mention @dosu. How did I do? Good | Irrelevant | Incorrect | Verbose | Hallucination | Report 🐛 | Other |
Beta Was this translation helpful? Give feedback.
Yes, when you use the Storybook Vitest addon, it automatically generates a default "smoke test" for each story—even if you haven't written any play functions or explicit tests. This test simply checks that your story renders without errors. If you see a single test named "Default" passing, that's this render test for your default story. It's not strictly required, but it provides a basic safety net to catch rendering issues early. You can configure which stories are tested or skip these if you want—see the official docs for details.
To reply, just mention @dosu.
How did I do? Good | Irrelevant | Incorrect | Verbose | Hallucination | Report 🐛 | Other
