mirror of
https://github.com/discourse/discourse.git
synced 2025-06-09 05:46:45 +08:00
DEV: Update ember-qunit to 6.0.0 (#19080)
Long story short - bumping ember-qunit upgrades webpack, and sinon is not compatible with webpack v5. It uses node's `util` module and that is no longer polyfilled by webpack by default.
This PR adds the `util` polyfill (😑, but what can you do) and also injects a stub of `process` (so polyfill + sinon actually work)
This commit is contained in:
@ -64,6 +64,26 @@ module.exports = function (defaults) {
|
|||||||
optimization: {
|
optimization: {
|
||||||
moduleIds: "size", // Consistent module references https://github.com/ef4/ember-auto-import/issues/478#issuecomment-1000526638
|
moduleIds: "size", // Consistent module references https://github.com/ef4/ember-auto-import/issues/478#issuecomment-1000526638
|
||||||
},
|
},
|
||||||
|
resolve: {
|
||||||
|
fallback: {
|
||||||
|
util: require.resolve("util/"),
|
||||||
|
},
|
||||||
|
},
|
||||||
|
module: {
|
||||||
|
rules: [
|
||||||
|
{
|
||||||
|
test: require.resolve("util/"),
|
||||||
|
use: [
|
||||||
|
{
|
||||||
|
loader: "imports-loader",
|
||||||
|
options: {
|
||||||
|
additionalCode: "var process = { env: {} };",
|
||||||
|
},
|
||||||
|
},
|
||||||
|
],
|
||||||
|
},
|
||||||
|
],
|
||||||
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
fingerprint: {
|
fingerprint: {
|
||||||
|
@ -68,7 +68,7 @@
|
|||||||
"ember-load-initializers": "^2.1.1",
|
"ember-load-initializers": "^2.1.1",
|
||||||
"ember-modifier": "^3.2.7",
|
"ember-modifier": "^3.2.7",
|
||||||
"ember-on-resize-modifier": "^1.1.0",
|
"ember-on-resize-modifier": "^1.1.0",
|
||||||
"ember-qunit": "^5.1.5",
|
"ember-qunit": "^6.0.0",
|
||||||
"ember-rfc176-data": "^0.3.17",
|
"ember-rfc176-data": "^0.3.17",
|
||||||
"ember-source": "~3.28.10",
|
"ember-source": "~3.28.10",
|
||||||
"ember-test-selectors": "^6.0.0",
|
"ember-test-selectors": "^6.0.0",
|
||||||
@ -108,6 +108,8 @@
|
|||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"ember-cached-decorator-polyfill": "^1.0.1",
|
"ember-cached-decorator-polyfill": "^1.0.1",
|
||||||
"ember-cli-deprecation-workflow": "^2.1.0",
|
"ember-cli-deprecation-workflow": "^2.1.0",
|
||||||
"ember-exam": "^8.0.0"
|
"ember-exam": "^8.0.0",
|
||||||
|
"imports-loader": "^4.0.1",
|
||||||
|
"util": "^0.12.5"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user