Update addons/storyshots/storyshots-core/src/api/index.ts

This commit is contained in:
Tom Coleman 2021-10-07 13:51:31 +11:00 committed by GitHub
parent 6f5833c472
commit d48dc79e06
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -40,7 +40,7 @@ function testStorySnapshots(options: StoryshotsOptions = {}) {
addons.setChannel(mockChannel());
// Add a mock EventSource class to be used by
// Add a mock EventSource class as it is extended by the `StoryIndexClient` (we don't actually use that in v6 mode)
if (!global.EventSource) global.EventSource = EventSourceStandin;
const { storybook, framework, renderTree, renderShallowTree } = loadFramework(options);