-
Notifications
You must be signed in to change notification settings - Fork 73
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
15 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -69,34 +69,34 @@ describe('installArchiveDependencies', () => { | |
it('successfully installs list of dependencies for Playwright if SB package is not found and Essentials is not found', async () => { | ||
await installArchiveDependencies({}, 'playwright') | ||
expect(execaCommand).toHaveBeenCalledOnce() | ||
expect(execaCommand).toHaveBeenCalledWith('yarn add -D chromatic chromatic-playwright storybook@latest @storybook/addon-essentials@latest @storybook/server-webpack5@latest') | ||
expect(execaCommand).toHaveBeenCalledWith('yarn add -D chromatic @chromatic-com/playwright storybook@latest @storybook/addon-essentials@latest @storybook/server-webpack5@latest') | ||
}) | ||
it('successfully installs list of dependencies for Cypress if SB package is not found and Essentials is not found', async () => { | ||
await installArchiveDependencies({}, 'cypress') | ||
expect(execaCommand).toHaveBeenCalledOnce() | ||
expect(execaCommand).toHaveBeenCalledWith('yarn add -D chromatic chromatic-cypress storybook@latest @storybook/addon-essentials@latest @storybook/server-webpack5@latest') | ||
expect(execaCommand).toHaveBeenCalledWith('yarn add -D chromatic @chromatic-com/cypress storybook@latest @storybook/addon-essentials@latest @storybook/server-webpack5@latest') | ||
}) | ||
it('successfully installs list of dependencies if SB package is found and Essentials is not found', async () => { | ||
await installArchiveDependencies({devDependencies: {'storybook': '7.6.5'}}, 'playwright') | ||
expect(execaCommand).toHaveBeenCalledOnce() | ||
expect(execaCommand).toHaveBeenCalledWith('yarn add -D chromatic chromatic-playwright @storybook/[email protected] @storybook/[email protected]') | ||
expect(execaCommand).toHaveBeenCalledWith('yarn add -D chromatic @chromatic-com/playwright @storybook/[email protected] @storybook/[email protected]') | ||
}) | ||
it('successfully installs list of dependencies if SB package is found and Essentials is found in devDependencies', async () => { | ||
await installArchiveDependencies({devDependencies: {storybook: '7.6.5', '@storybook/addon-essentials': '7.6.5'}}, 'playwright') | ||
expect(execaCommand).toHaveBeenCalledOnce() | ||
expect(execaCommand).toHaveBeenCalledWith('yarn add -D chromatic chromatic-playwright @storybook/[email protected]') | ||
expect(execaCommand).toHaveBeenCalledWith('yarn add -D chromatic @chromatic-com/playwright @storybook/[email protected]') | ||
vi.clearAllMocks() | ||
}) | ||
it('successfully installs list of dependencies if SB package is found and Essentials is found in dependencies', async () => { | ||
await installArchiveDependencies({dependencies: {storybook: '7.6.5', '@storybook/addon-essentials': '7.6.5'}}, 'playwright') | ||
expect(execaCommand).toHaveBeenCalledOnce() | ||
expect(execaCommand).toHaveBeenCalledWith('yarn add -D chromatic chromatic-playwright @storybook/[email protected]') | ||
expect(execaCommand).toHaveBeenCalledWith('yarn add -D chromatic @chromatic-com/playwright @storybook/[email protected]') | ||
vi.clearAllMocks() | ||
}) | ||
it('successfully installs list of dependencies if SB package is not found and Essentials is found in dependencies', async () => { | ||
await installArchiveDependencies({dependencies: {'@storybook/addon-essentials': '7.6.5'}}, 'playwright') | ||
expect(execaCommand).toHaveBeenCalledOnce() | ||
expect(execaCommand).toHaveBeenCalledWith('yarn add -D chromatic chromatic-playwright [email protected] @storybook/[email protected]') | ||
expect(execaCommand).toHaveBeenCalledWith('yarn add -D chromatic @chromatic-com/playwright [email protected] @storybook/[email protected]') | ||
vi.clearAllMocks() | ||
}) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters