You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
We use @storybook/addon-vitest for story interaction tests locally and in CI. In merge-request pipelines, Storybook is built and deployed before the tests run. We want the tests to validate that deployed artifact, not rebuild the stories through Vitest’s local Vite server.
The storybookUrl option looks like a remote target, but it is only used for failure links. Vitest still discovers and transforms local story files and serves them through /__vitest_test__ on its own server, port 63315.
This creates a migration gap from @storybook/test-runner, which supports --url/TARGET_URL and index.json mode for deployed Storybooks. Moving to the recommended Vitest addon removes that capability.
Describe the solution you'd like
Add a remote target mode to @storybook/addon-vitest, separate from the existing debug-only storybookUrl option. For example:
Execute the deployed story bundles and their play functions.
Preserve Vitest reporting, tag filtering, assertions, and exit codes.
Work with normal and remote Playwright providers, including browserType.connect() services such as Browserless.
Report the deployed story URL on failure.
Fail clearly when the remote artifact is unavailable or incompatible.
storybookUrl should remain a debugging-link option, or be renamed/documented so it cannot be confused with the execution target.
Describe alternatives you've considered
@storybook/test-runner supports deployed Storybooks, but it introduces Jest after the project has standardized on Vitest and Storybook recommends migrating away from it.
A custom Playwright crawler can read index.json and open every iframe, but it must reimplement Storybook’s play-function lifecycle, tag filtering, error handling, and reporting.
Exposing Vitest’s local browser server through a tunnel allows Browserless to run the tests, but it still tests stories transformed from the CI checkout. It does not validate the deployed Storybook artifact.
Setting storybookUrl to the deployed URL only changes failure links; it does not change where tests execute.
Are you able to assist to bring the feature to reality?
no
Additional context
A closely related report is #33347. It shows a migration from test-runner to addon-vitest where CI is triggered after Storybook deployment and the deployed URL is passed as storybookUrl, but Vitest still loads tests from localhost:63315:
Vitest Browser Mode intentionally focuses on component testing rather than deployed-site E2E testing, so this likely needs to be implemented by the Storybook integration:
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Is your feature request related to a problem? Please describe.
We use
@storybook/addon-vitestfor story interaction tests locally and in CI. In merge-request pipelines, Storybook is built and deployed before the tests run. We want the tests to validate that deployed artifact, not rebuild the stories through Vitest’s local Vite server.The
storybookUrloption looks like a remote target, but it is only used for failure links. Vitest still discovers and transforms local story files and serves them through/__vitest_test__on its own server, port 63315.This creates a migration gap from
@storybook/test-runner, which supports--url/TARGET_URLandindex.jsonmode for deployed Storybooks. Moving to the recommended Vitest addon removes that capability.Describe the solution you'd like
Add a remote target mode to
@storybook/addon-vitest, separate from the existing debug-onlystorybookUrloption. For example:When
targetUrlis set, the addon should:storybookUrlshould remain a debugging-link option, or be renamed/documented so it cannot be confused with the execution target.Describe alternatives you've considered
@storybook/test-runnersupports deployed Storybooks, but it introduces Jest after the project has standardized on Vitest and Storybook recommends migrating away from it.A custom Playwright crawler can read index.json and open every iframe, but it must reimplement Storybook’s play-function lifecycle, tag filtering, error handling, and reporting.
Exposing Vitest’s local browser server through a tunnel allows Browserless to run the tests, but it still tests stories transformed from the CI checkout. It does not validate the deployed Storybook artifact.
Setting
storybookUrlto the deployed URL only changes failure links; it does not change where tests execute.Are you able to assist to bring the feature to reality?
no
Additional context
A closely related report is #33347. It shows a migration from test-runner to addon-vitest where CI is triggered after Storybook deployment and the deployed URL is passed as storybookUrl, but Vitest still loads tests from localhost:63315:
#33347
The legacy deployed-Storybook behavior being replaced is documented here:
https://github.com/storybookjs/test-runner#running-against-a-deployed-storybook
Vitest Browser Mode intentionally focuses on component testing rather than deployed-site E2E testing, so this likely needs to be implemented by the Storybook integration:
vitest-dev/vitest#5828
All reactions