Skip to content

Commit

Permalink
fix(storybook): ignore addon-notes from version update (#10568)
Browse files Browse the repository at this point in the history
ISSUES CLOSED:  #10484
  • Loading branch information
mandarini committed Jun 3, 2022
1 parent a49ee7e commit 189c036
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
Expand Up @@ -22,6 +22,7 @@ describe('migrate-defaults-5-to-6 Generator', () => {
'@nrwl/workspace': '10.4.0',
'@storybook/addon-knobs': '^5.3.8',
'@storybook/angular': '^5.3.8',
'@storybook/addon-notes': '5.3.21',
},
};
});
Expand Down Expand Up @@ -60,17 +61,19 @@ describe('migrate-defaults-5-to-6 Generator', () => {
});
});

it('should update Storybook packages to latest version', async () => {
it('should update Storybook packages to latest version and ignore the ones to be ignored', async () => {
migrateDefaultsGenerator(appTree);

const packageJson = readJson(appTree, 'package.json');
// general deps
expect(packageJson.devDependencies['@storybook/angular']).toEqual(
storybookVersion
);
expect(packageJson.devDependencies['@storybook/addon-knobs']).toEqual(
storybookVersion
);
expect(packageJson.devDependencies['@storybook/addon-notes']).toEqual(
'5.3.21'
);
});

it('should update root config to version 6', async () => {
Expand Down
Expand Up @@ -85,6 +85,7 @@ function maybeUpdateVersion(tree: Tree): GeneratorCallback {
'@storybook/testing-react',
'@storybook/testing-vue',
'@storybook/testing-vue3',
'@storybook/addon-notes',
];

json.dependencies = json.dependencies || {};
Expand Down

0 comments on commit 189c036

Please sign in to comment.