Skip to content

Commit

Permalink
Fix failing main (#903)
Browse files Browse the repository at this point in the history
  • Loading branch information
JLHwung committed Apr 20, 2021
1 parent eafd20d commit f3538d0
Show file tree
Hide file tree
Showing 3 changed files with 165 additions and 182 deletions.
2 changes: 1 addition & 1 deletion package.json
Expand Up @@ -44,7 +44,7 @@
"react-intl-webpack-plugin": "^0.3.0",
"rimraf": "^3.0.0",
"semver": "7.3.2",
"webpack": "^5.4.0"
"webpack": "^5.34.0"
},
"scripts": {
"clean": "rimraf lib/",
Expand Down
12 changes: 6 additions & 6 deletions test/sourcemaps.test.js
Expand Up @@ -117,12 +117,12 @@ test.cb("should output webpack's sourcemap properly when set 'inline'", t => {

if (isWebpack5) {
t.is(
mapObj.sources[0],
mapObj.sources[3],
"webpack://babel-loader/./test/fixtures/basic.js",
);

// Ensure that the map contains the original code, not the compiled src.
t.falsy(mapObj.sourcesContent[2].includes("__esModule"));
t.falsy(mapObj.sourcesContent[3].includes("__esModule"));
} else {
t.is(mapObj.sources[1], "webpack:///./test/fixtures/basic.js");

Expand Down Expand Up @@ -232,13 +232,13 @@ test.cb("should disable sourcemap output with 'sourceMaps:false'", t => {

if (isWebpack5) {
t.is(
mapObj.sources[0],
mapObj.sources[3],
"webpack://babel-loader/./test/fixtures/basic.js",
);

// Ensure that the code contains Babel's compiled output, because
// sourcemaps from Babel are disabled.
t.truthy(mapObj.sourcesContent[2].includes("__esModule"));
t.truthy(mapObj.sourcesContent[3].includes("__esModule"));
} else {
t.is(mapObj.sources[1], "webpack:///./test/fixtures/basic.js");

Expand Down Expand Up @@ -295,13 +295,13 @@ test.cb("should disable sourcemap output with 'sourceMap:false'", t => {

if (isWebpack5) {
t.is(
mapObj.sources[0],
mapObj.sources[3],
"webpack://babel-loader/./test/fixtures/basic.js",
);

// Ensure that the code contains Babel's compiled output, because
// sourcemaps from Babel are disabled.
t.truthy(mapObj.sourcesContent[2].includes("__esModule"));
t.truthy(mapObj.sourcesContent[3].includes("__esModule"));
} else {
t.is(mapObj.sources[1], "webpack:///./test/fixtures/basic.js");

Expand Down

0 comments on commit f3538d0

Please sign in to comment.