Skip to content

Commit 40b1a77

Browse files
test: added
1 parent 080e54f commit 40b1a77

File tree

49 files changed

+271
-1
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

49 files changed

+271
-1
lines changed

lib/javascript/CommonJsChunkFormatPlugin.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
const { ConcatSource, RawSource } = require("webpack-sources");
99
const RuntimeGlobals = require("../RuntimeGlobals");
1010
const Template = require("../Template");
11+
const { getUndoPath } = require("../util/identifier");
1112
const {
1213
getChunkFilenameTemplate,
1314
getCompilationHooks
@@ -16,7 +17,6 @@ const {
1617
generateEntryStartup,
1718
updateHashForEntryStartup
1819
} = require("./StartupHelpers");
19-
const { getUndoPath } = require("../util/identifier");
2020

2121
/** @typedef {import("../Chunk")} Chunk */
2222
/** @typedef {import("../Compiler")} Compiler */
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
module.exports = {
2+
findBundle: function () {
3+
return [
4+
"./dir5/dir6/runtime~one.js",
5+
"./one.js",
6+
"./dir5/dir6/runtime~two.js",
7+
"./dir2/two.js",
8+
"./dir5/dir6/runtime~three.js",
9+
"./three.js",
10+
"./dir5/dir6/runtime~four.js",
11+
"./dir4/four.js",
12+
"./dir5/dir6/runtime~five.js",
13+
"./dir5/dir6/five.js",
14+
"./dir5/dir6/runtime~six.js",
15+
"./dir5/dir6/six.js"
16+
];
17+
}
18+
};
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
/** @type {import("../../../../").Configuration} */
2+
module.exports = {
3+
output: {
4+
filename: "[name].js"
5+
},
6+
target: ["es2022", "async-node"],
7+
entry: {
8+
one: "./one",
9+
"dir2/two": "./two",
10+
"/three": "./three",
11+
"/dir4/four": "./four",
12+
"/dir5/dir6/five": "./five",
13+
"/dir5/dir6/six": "./six"
14+
},
15+
optimization: {
16+
runtimeChunk: {
17+
name: entrypoint => {
18+
return `dir5/dir6/runtime~${entrypoint.name.split("/").pop()}`;
19+
}
20+
}
21+
}
22+
};
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
module.exports = {
2+
findBundle: function () {
3+
return [
4+
"./dir5/dir6/runtime~one.mjs",
5+
"./one.mjs",
6+
"./dir5/dir6/runtime~two.mjs",
7+
"./dir2/two.mjs",
8+
"./dir5/dir6/runtime~three.mjs",
9+
"./three.mjs",
10+
"./dir5/dir6/runtime~four.mjs",
11+
"./dir4/four.mjs",
12+
"./dir5/dir6/runtime~five.mjs",
13+
"./dir5/dir6/five.mjs",
14+
"./dir5/dir6/runtime~six.mjs",
15+
"./dir5/dir6/six.mjs"
16+
];
17+
}
18+
};
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
/** @type {import("../../../../").Configuration} */
2+
module.exports = {
3+
output: {
4+
filename: "[name].mjs",
5+
module: true
6+
},
7+
target: ["es2022", "async-node"],
8+
entry: {
9+
one: "./one",
10+
"dir2/two": "./two",
11+
"/three": "./three",
12+
"/dir4/four": "./four",
13+
"/dir5/dir6/five": "./five",
14+
"/dir5/dir6/six": "./six"
15+
},
16+
optimization: {
17+
runtimeChunk: {
18+
name: entrypoint => {
19+
return `dir5/dir6/runtime~${entrypoint.name.split("/").pop()}`;
20+
}
21+
}
22+
},
23+
experiments: {
24+
outputModule: true
25+
}
26+
};
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
module.exports = {
2+
findBundle: function () {
3+
return [
4+
"./runtime/one.js",
5+
"./one.js",
6+
"./runtime/dir2/two.js",
7+
"./dir2/two.js",
8+
"./runtime/three.js",
9+
"./three.js",
10+
"./runtime/dir4/four.js",
11+
"./dir4/four.js",
12+
"./runtime/dir5/dir6/five.js",
13+
"./dir5/dir6/five.js",
14+
"./runtime/dir5/dir6/six.js",
15+
"./dir5/dir6/six.js"
16+
];
17+
}
18+
};
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
/** @type {import("../../../../").Configuration} */
2+
module.exports = {
3+
output: {
4+
filename: "[name].js"
5+
},
6+
target: ["es2022", "async-node"],
7+
entry: {
8+
one: "./one",
9+
"dir2/two": "./two",
10+
"/three": "./three",
11+
"/dir4/four": "./four",
12+
"/dir5/dir6/five": "./five",
13+
"/dir5/dir6/six": "./six"
14+
},
15+
optimization: {
16+
runtimeChunk: {
17+
name: entrypoint => {
18+
return `runtime/${entrypoint.name.replace(/^\/+/g, "")}`;
19+
}
20+
}
21+
}
22+
};
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
module.exports = {
2+
findBundle: function () {
3+
return [
4+
"./runtime/one.mjs",
5+
"./one.mjs",
6+
"./runtime/dir2/two.mjs",
7+
"./dir2/two.mjs",
8+
"./runtime/three.mjs",
9+
"./three.mjs",
10+
"./runtime/dir4/four.mjs",
11+
"./dir4/four.mjs",
12+
"./runtime/dir5/dir6/five.mjs",
13+
"./dir5/dir6/five.mjs",
14+
"./runtime/dir5/dir6/six.mjs",
15+
"./dir5/dir6/six.mjs"
16+
];
17+
}
18+
};
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
/** @type {import("../../../../").Configuration} */
2+
module.exports = {
3+
output: {
4+
filename: "[name].mjs",
5+
module: true
6+
},
7+
target: ["es2022", "async-node"],
8+
entry: {
9+
one: "./one",
10+
"dir2/two": "./two",
11+
"/three": "./three",
12+
"/dir4/four": "./four",
13+
"/dir5/dir6/five": "./five",
14+
"/dir5/dir6/six": "./six"
15+
},
16+
optimization: {
17+
runtimeChunk: {
18+
name: entrypoint => {
19+
return `runtime/${entrypoint.name.replace(/^\/+/g, "")}`;
20+
}
21+
}
22+
},
23+
experiments: {
24+
outputModule: true
25+
}
26+
};
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
module.exports = {
2+
findBundle: function () {
3+
return [
4+
"./runtime.js",
5+
"./one.js",
6+
"./dir2/two.js",
7+
"./three.js",
8+
"./dir4/four.js",
9+
"./dir5/dir6/five.js",
10+
"./dir5/dir6/six.js"
11+
];
12+
}
13+
};
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
/** @type {import("../../../../").Configuration} */
2+
module.exports = {
3+
output: {
4+
filename: "[name].js"
5+
},
6+
target: ["es2022", "async-node"],
7+
entry: {
8+
one: "./one",
9+
"dir2/two": "./two",
10+
"/three": "./three",
11+
"/dir4/four": "./four",
12+
"/dir5/dir6/five": "./five",
13+
"/dir5/dir6/six": "./six"
14+
},
15+
optimization: {
16+
runtimeChunk: "single"
17+
}
18+
};
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
module.exports = {
2+
findBundle: function () {
3+
return [
4+
"./runtime.mjs",
5+
"./one.mjs",
6+
"./dir2/two.mjs",
7+
"./three.mjs",
8+
"./dir4/four.mjs",
9+
"./dir5/dir6/five.mjs",
10+
"./dir5/dir6/six.mjs"
11+
];
12+
}
13+
};
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
it("should compile", () => {});
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
/** @type {import("../../../../").Configuration} */
2+
module.exports = {
3+
output: {
4+
filename: "[name].mjs",
5+
module: true
6+
},
7+
target: ["es2022", "async-node"],
8+
entry: {
9+
one: "./one",
10+
"dir2/two": "./two",
11+
"/three": "./three",
12+
"/dir4/four": "./four",
13+
"/dir5/dir6/five": "./five",
14+
"/dir5/dir6/six": "./six"
15+
},
16+
optimization: {
17+
runtimeChunk: "single"
18+
},
19+
experiments: {
20+
outputModule: true
21+
}
22+
};

0 commit comments

Comments
 (0)