Skip to content

Commit af3b149

Browse files
fix: keep the unused-modules fixtures on the node 10 baseline
1 parent 9aa5a6e commit af3b149

15 files changed

Lines changed: 15 additions & 15 deletions

File tree

‎test/configCases/performance/unused-modules-clean/index.js‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,6 @@ import { value } from "./read";
33

44
it("should report nothing when every bundled module is used or dropped", () => {
55
expect(value).toBe(42);
6-
expect(globalThis.__READ_RAN__).toBe(true);
6+
expect(global.__READ_RAN__).toBe(true);
77
expect(__STATS__.warnings).toHaveLength(0);
88
});
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
export const value = 42;
22

3-
globalThis.__READ_RAN__ = true;
3+
global.__READ_RAN__ = true;

‎test/configCases/performance/unused-modules-error/index.js‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,5 +7,5 @@ it("should report the unused module as an error", () => {
77
// `read.js` has a side effect too, but something reads its export, so it is
88
// not bundled for nothing.
99
expect(value).toBe(42);
10-
expect(globalThis.__ANALYTICS__.started).toBe(true);
10+
expect(global.__ANALYTICS__.started).toBe(true);
1111
});
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
export const value = 42;
22

3-
globalThis.__READ_RAN__ = true;
3+
global.__READ_RAN__ = true;
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
export const helper = () => "never called";
22

3-
globalThis.__ANALYTICS__ = { started: true };
3+
global.__ANALYTICS__ = { started: true };

‎test/configCases/performance/unused-modules-no-analysis/index.js‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,6 @@ it("should stay quiet when side effects were never analysed", () => {
55
// With 'optimization.sideEffects' off nothing records which statement keeps
66
// a module, so there is no attribution to report and the hint says nothing.
77
expect(value).toBe(42);
8-
expect(globalThis.__ANALYTICS__.started).toBe(true);
8+
expect(global.__ANALYTICS__.started).toBe(true);
99
expect(__STATS__.warnings).toHaveLength(0);
1010
});
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
export const value = 42;
22

3-
globalThis.__READ_RAN__ = true;
3+
global.__READ_RAN__ = true;
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
export const helper = () => "never called";
22

3-
globalThis.__ANALYTICS__ = { started: true };
3+
global.__ANALYTICS__ = { started: true };
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
export const value = 42;
22

3-
globalThis.__READ_RAN__ = true;
3+
global.__READ_RAN__ = true;
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
export const helper = () => "never called";
22

3-
globalThis.__ANALYTICS__ = { started: true };
3+
global.__ANALYTICS__ = { started: true };

0 commit comments

Comments
 (0)