Skip to content

Commit

Permalink
fix test
Browse files Browse the repository at this point in the history
  • Loading branch information
smouillour committed Oct 11, 2023
1 parent 90919b7 commit f8b7bde
Showing 1 changed file with 4 additions and 8 deletions.
12 changes: 4 additions & 8 deletions fork/dynamic-cdn-webpack-plugin/src/find.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,9 @@ describe('findPackages', () => {
'/node_modules/react/index.js': 'console.log("react");',
'/node_modules/react/package.json': '{"name": "react", "version": "16.14.0"}',
'/node_modules/@types/classnames/index.js': 'console.log("@types/classnames");',
'/node_modules/@talend/react-components/index.js':
'console.log("@talend/react-components");',
'/node_modules/@talend/react-components/node_modules/react/index.js':
'console.log("react");',
'/node_modules/@talend/react-containers/index.js':
'console.log("@talend/react-containers");',
'/node_modules/@talend/react-components/index.js': 'console.log("@talend/react-components");',
'/node_modules/@talend/react-components/node_modules/react/index.js': 'console.log("react");',
'/node_modules/@talend/react-containers/index.js': 'console.log("@talend/react-containers");',
};

beforeEach(() => {
Expand All @@ -35,9 +32,8 @@ describe('findPackages', () => {
const result = findPackages(undefined, 'react');

// then
expect(result.length).toBe(2);
expect(result.length).toBe(1);
expect(result[0]).toBe('/node_modules/react');
expect(result[1]).toBe('/node_modules/@talend/react-components/node_modules/react');
});

test('should find non scoped package', () => {
Expand Down

0 comments on commit f8b7bde

Please sign in to comment.