Skip to content

Commit

Permalink
chore: enable oxc_resolver in webpack tests (#4374)
Browse files Browse the repository at this point in the history
* chore: enable oxc_resolver in webpack tests

closes #4317

* add newResolver to webpack-test/TestCases.template.js
  • Loading branch information
Boshen authored Oct 23, 2023
1 parent a19b474 commit f4a3a08
Show file tree
Hide file tree
Showing 21 changed files with 19 additions and 37 deletions.
3 changes: 3 additions & 0 deletions webpack-test/ConfigTestCases.template.js
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,9 @@ const describeCases = config => {
// path.resolve(__dirname, "../node_modules")
// ];
// }
if (!options.experiments) options.experiments = {};
if (!options.experiments.rspackFuture) options.experiments.rspackFuture = {};
options.experiments.rspackFuture.newResolver = true;
});
testConfig = {
findBundle: function(i, options) {
Expand Down
5 changes: 4 additions & 1 deletion webpack-test/TestCases.template.js
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,10 @@ const describeCases = config => {
// RSPACK exclusive: Rspack enables `css` by default.
// Turning off here to fallback to webpack's default css processing logic.
css: false,
...(config.module ? { outputModule: true } : {})
...(config.module ? { outputModule: true } : {}),
rspackFuture: {
newResolver: true
}
},
infrastructureLogging: config.cache && {
debug: true,
Expand Down
3 changes: 0 additions & 3 deletions webpack-test/cases/resolving/browser-field/test.filter.js
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@

module.exports = () => {return false}


Original file line number Diff line number Diff line change
@@ -1,4 +1 @@

module.exports = () => {return false}


3 changes: 0 additions & 3 deletions webpack-test/cases/resolving/context/test.filter.js
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@

module.exports = () => {return false}


3 changes: 0 additions & 3 deletions webpack-test/cases/resolving/data-uri/test.filter.js
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@

module.exports = () => {return false}


3 changes: 0 additions & 3 deletions webpack-test/cases/resolving/issue-11555/test.filter.js
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@

module.exports = () => {return false}


3 changes: 0 additions & 3 deletions webpack-test/cases/resolving/issue-2986/test.filter.js
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@

module.exports = () => {return false}


5 changes: 1 addition & 4 deletions webpack-test/cases/resolving/query/test.filter.js
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@

module.exports = () => {return false}


module.exports = () => {return true}
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@

module.exports = () => {return false}


Original file line number Diff line number Diff line change
@@ -1 +1 @@
module.exports = () => {return false}
module.exports = () => {return false}
Original file line number Diff line number Diff line change
@@ -1 +1 @@
module.exports = () => {return false}
module.exports = () => {return false}
Original file line number Diff line number Diff line change
@@ -1 +1 @@
module.exports = () => {return false}
module.exports = () => {return false}
2 changes: 1 addition & 1 deletion webpack-test/configCases/resolve/fallback/test.filter.js
Original file line number Diff line number Diff line change
@@ -1 +1 @@
module.exports = () => {return false}
module.exports = () => {return true}
Original file line number Diff line number Diff line change
@@ -1 +1 @@
module.exports = () => {return false}
module.exports = () => {return false}
Original file line number Diff line number Diff line change
@@ -1 +1 @@
module.exports = () => {return false}
module.exports = () => {return false}
Original file line number Diff line number Diff line change
@@ -1 +1 @@
module.exports = () => {return false}
module.exports = () => {return true}
Original file line number Diff line number Diff line change
@@ -1 +1 @@
module.exports = () => {return false}
module.exports = () => {return false}
Original file line number Diff line number Diff line change
@@ -1 +1 @@
module.exports = () => {return false}
module.exports = () => {return true}
Original file line number Diff line number Diff line change
@@ -1 +1 @@
module.exports = () => {return false}
module.exports = () => {return false}
Original file line number Diff line number Diff line change
@@ -1 +1 @@
module.exports = () => {return false}
module.exports = () => {return false}

0 comments on commit f4a3a08

Please sign in to comment.