Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Remove webpack and webpack-cli dependencies #614

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 1 addition & 4 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,10 +63,7 @@ commands:
run_test_bundlers:
description: rerun unit tests on webpack and browserify bundled files
steps:
- run: npm install browserify webpack webpack-cli
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The fix for the bug is to add --no-save here, as mentioned at #604 (comment)

- run: |
export PATH=$PATH:$PWD/node_modules/.bin
node ./scripts/run-module-bundlers-smoketests.js
- run: npm run test-module-bundlers-smoketests

run_xephyr:
description: run Xephyr on DISPLAY=:10
Expand Down
6 changes: 3 additions & 3 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ respectively, and finally execute the unit tests on the generated dist files.
This project provides two test suites:

- unit tests (which only require Node.js to run)
- module bundlers smoke tests (which requires also browserify and webpack to be installed globally)
- module bundlers smoke tests
- integration tests (which requires also a stable version of Chrome and Firefox)

### Unit Tests
Expand All @@ -51,8 +51,8 @@ by running `npm run test-coverage`.

### Module Bundler smoketests

The shell script `test/run-module-bundlers-smoketests.sh` runs browserify and webpack,
to verify that the most commonly used module bundlers are not raising any unexpected error
`npm run test-module-bundlers-smoketests` runs browserify and webpack,
to verify that the most commonly used module bundlers are not raising any unexpected error
while building a bundle that requires this library.

### Integration Tests
Expand Down
9 changes: 6 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@
"homepage": "https://github.com/mozilla/webextension-polyfill",
"devDependencies": {
"@babel/core": "7.18.10",
"@babel/eslint-parser": "7.19.1",
"@babel/preset-env": "7.18.10",
"@babel/register": "7.18.9",
"@babel/eslint-parser": "7.19.1",
"babel-preset-minify": "0.5.2",
"browserify": "17.0.0",
"chai": "4.3.6",
Expand All @@ -44,7 +44,9 @@
"sinon": "14.0.0",
"tape": "5.5.3",
"tape-async": "2.3.0",
"tmp": "0.2.1"
"tmp": "0.2.1",
"webpack": "5.91.0",
"webpack-cli": "5.1.4"
},
"nyc": {
"reporter": [
Expand All @@ -63,6 +65,7 @@
"test-minified": "cross-env TEST_MINIFIED_POLYFILL=1 mocha",
"test-integration": "tape test/integration/test-*",
"test-integration:chrome": "cross-env TEST_BROWSER_TYPE=chrome npm run test-integration",
"test-integration:firefox": "cross-env TEST_BROWSER_TYPE=firefox npm run test-integration"
"test-integration:firefox": "cross-env TEST_BROWSER_TYPE=firefox npm run test-integration",
"test-module-bundlers-smoketests": "./scripts/run-module-bundlers-smoketests.js"
}
}