Skip to content

Commit 5d23cb4

Browse files
authored
Exclude generated files from user tests (#23371)
* Exclude generated files from user tests The top 3 offenders, at least: bcryptjs, bluebird and lodash. * Clean url-search-params too Only need to build the commonjs original, not the browserified ones.
1 parent b363240 commit 5d23cb4

File tree

8 files changed

+18
-698
lines changed

8 files changed

+18
-698
lines changed

tests/baselines/reference/user/bcryptjs.log

Lines changed: 9 additions & 112 deletions
Large diffs are not rendered by default.

tests/baselines/reference/user/bluebird.log

Lines changed: 0 additions & 211 deletions
Large diffs are not rendered by default.

tests/baselines/reference/user/lodash.log

Lines changed: 0 additions & 316 deletions
Large diffs are not rendered by default.

tests/baselines/reference/user/url-search-params.log

Lines changed: 0 additions & 55 deletions
Original file line numberDiff line numberDiff line change
@@ -1,60 +1,5 @@
11
Exit Code: 1
22
Standard output:
3-
node_modules/url-search-params/build/url-search-params.js(2,5): error TS2322: Type '{ new (init?: string | URLSearchParams | undefined): URLSearchParams; prototype: URLSearchParams; }' is not assignable to type '(query: any) => void'.
4-
Type '{ new (init?: string | URLSearchParams | undefined): URLSearchParams; prototype: URLSearchParams; }' provides no match for the signature '(query: any): void'.
5-
node_modules/url-search-params/build/url-search-params.js(2,5): error TS2403: Subsequent variable declarations must have the same type. Variable 'URLSearchParams' must be of type '{ new (init?: string | URLSearchParams | undefined): URLSearchParams; prototype: URLSearchParams; }', but here has type '(query: any) => void'.
6-
node_modules/url-search-params/build/url-search-params.js(2,3851): error TS2532: Object is possibly 'undefined'.
7-
node_modules/url-search-params/build/url-search-params.js(2,3851): error TS2532: Object is possibly 'undefined'.
8-
node_modules/url-search-params/build/url-search-params.js(2,3851): error TS2684: The 'this' context of type '(() => any) | undefined' is not assignable to method's 'this' of type 'Function'.
9-
Type 'undefined' is not assignable to type 'Function'.
10-
node_modules/url-search-params/build/url-search-params.js(2,3918): error TS2532: Object is possibly 'undefined'.
11-
node_modules/url-search-params/build/url-search-params.js(2,3918): error TS2532: Object is possibly 'undefined'.
12-
node_modules/url-search-params/build/url-search-params.js(2,3918): error TS2684: The 'this' context of type '((v: any) => void) | undefined' is not assignable to method's 'this' of type 'Function'.
13-
Type 'undefined' is not assignable to type 'Function'.
14-
node_modules/url-search-params/build/url-search-params.js(2,4005): error TS2532: Object is possibly 'undefined'.
15-
node_modules/url-search-params/build/url-search-params.js(2,4005): error TS2532: Object is possibly 'undefined'.
16-
node_modules/url-search-params/build/url-search-params.js(2,4005): error TS2684: The 'this' context of type '(() => any) | undefined' is not assignable to method's 'this' of type 'Function'.
17-
Type 'undefined' is not assignable to type 'Function'.
18-
node_modules/url-search-params/build/url-search-params.js(2,4074): error TS2532: Object is possibly 'undefined'.
19-
node_modules/url-search-params/build/url-search-params.js(2,4074): error TS2532: Object is possibly 'undefined'.
20-
node_modules/url-search-params/build/url-search-params.js(2,4074): error TS2684: The 'this' context of type '((v: any) => void) | undefined' is not assignable to method's 'this' of type 'Function'.
21-
Type 'undefined' is not assignable to type 'Function'.
22-
node_modules/url-search-params/build/url-search-params.js(2,4676): error TS2339: Property 'forEach' does not exist on type 'URLSearchParams'.
23-
node_modules/url-search-params/build/url-search-params.js(2,5038): error TS2339: Property 'keys' does not exist on type 'URLSearchParams'.
24-
node_modules/url-search-params/build/url-search-params.js(2,5077): error TS2339: Property 'forEach' does not exist on type 'URLSearchParams'.
25-
node_modules/url-search-params/build/url-search-params.js(2,5368): error TS2339: Property 'values' does not exist on type 'URLSearchParams'.
26-
node_modules/url-search-params/build/url-search-params.js(2,5411): error TS2339: Property 'forEach' does not exist on type 'URLSearchParams'.
27-
node_modules/url-search-params/build/url-search-params.js(2,5699): error TS2339: Property 'entries' does not exist on type 'URLSearchParams'.
28-
node_modules/url-search-params/build/url-search-params.js(2,5744): error TS2339: Property 'forEach' does not exist on type 'URLSearchParams'.
29-
node_modules/url-search-params/build/url-search-params.js(2,6099): error TS2339: Property 'entries' does not exist on type 'URLSearchParams'.
30-
node_modules/url-search-params/build/url-search-params.js(2,6165): error TS2339: Property 'sort' does not exist on type 'URLSearchParams'.
31-
node_modules/url-search-params/build/url-search-params.js(2,6203): error TS2339: Property 'entries' does not exist on type 'URLSearchParams'.
32-
node_modules/url-search-params/build/url-search-params.max.js(246,22): error TS2532: Object is possibly 'undefined'.
33-
node_modules/url-search-params/build/url-search-params.max.js(246,22): error TS2532: Object is possibly 'undefined'.
34-
node_modules/url-search-params/build/url-search-params.max.js(246,22): error TS2684: The 'this' context of type '(() => any) | undefined' is not assignable to method's 'this' of type 'Function'.
35-
Type 'undefined' is not assignable to type 'Function'.
36-
node_modules/url-search-params/build/url-search-params.max.js(250,15): error TS2532: Object is possibly 'undefined'.
37-
node_modules/url-search-params/build/url-search-params.max.js(250,15): error TS2532: Object is possibly 'undefined'.
38-
node_modules/url-search-params/build/url-search-params.max.js(250,15): error TS2684: The 'this' context of type '((v: any) => void) | undefined' is not assignable to method's 'this' of type 'Function'.
39-
Type 'undefined' is not assignable to type 'Function'.
40-
node_modules/url-search-params/build/url-search-params.max.js(256,22): error TS2532: Object is possibly 'undefined'.
41-
node_modules/url-search-params/build/url-search-params.max.js(256,22): error TS2532: Object is possibly 'undefined'.
42-
node_modules/url-search-params/build/url-search-params.max.js(256,22): error TS2684: The 'this' context of type '(() => any) | undefined' is not assignable to method's 'this' of type 'Function'.
43-
Type 'undefined' is not assignable to type 'Function'.
44-
node_modules/url-search-params/build/url-search-params.max.js(260,15): error TS2532: Object is possibly 'undefined'.
45-
node_modules/url-search-params/build/url-search-params.max.js(260,15): error TS2532: Object is possibly 'undefined'.
46-
node_modules/url-search-params/build/url-search-params.max.js(260,15): error TS2684: The 'this' context of type '((v: any) => void) | undefined' is not assignable to method's 'this' of type 'Function'.
47-
Type 'undefined' is not assignable to type 'Function'.
48-
node_modules/url-search-params/build/url-search-params.max.js(322,26): error TS2339: Property 'forEach' does not exist on type 'URLSearchParams'.
49-
node_modules/url-search-params/build/url-search-params.max.js(337,26): error TS2339: Property 'keys' does not exist on type 'URLSearchParams'.
50-
node_modules/url-search-params/build/url-search-params.max.js(339,12): error TS2339: Property 'forEach' does not exist on type 'URLSearchParams'.
51-
node_modules/url-search-params/build/url-search-params.max.js(358,26): error TS2339: Property 'values' does not exist on type 'URLSearchParams'.
52-
node_modules/url-search-params/build/url-search-params.max.js(360,12): error TS2339: Property 'forEach' does not exist on type 'URLSearchParams'.
53-
node_modules/url-search-params/build/url-search-params.max.js(379,26): error TS2339: Property 'entries' does not exist on type 'URLSearchParams'.
54-
node_modules/url-search-params/build/url-search-params.max.js(381,12): error TS2339: Property 'forEach' does not exist on type 'URLSearchParams'.
55-
node_modules/url-search-params/build/url-search-params.max.js(400,66): error TS2339: Property 'entries' does not exist on type 'URLSearchParams'.
56-
node_modules/url-search-params/build/url-search-params.max.js(404,26): error TS2339: Property 'sort' does not exist on type 'URLSearchParams'.
57-
node_modules/url-search-params/build/url-search-params.max.js(406,24): error TS2339: Property 'entries' does not exist on type 'URLSearchParams'.
583
node_modules/url-search-params/build/url-search-params.node.js(174,1): error TS2539: Cannot assign to 'URLSearchParams' because it is not a variable.
594
node_modules/url-search-params/build/url-search-params.node.js(174,44): error TS2339: Property 'URLSearchParams' does not exist on type 'Global'.
605

tests/cases/user/bcryptjs/tsconfig.json

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,5 +10,9 @@
1010
"types": ["node"],
1111
"lib": ["esnext", "dom"],
1212
},
13-
"include": ["node_modules/bcryptjs"]
13+
"include": [
14+
"node_modules/bcryptjs/scripts",
15+
"node_modules/bcryptjs/src",
16+
"node_modules/bcryptjs/tests"
17+
]
1418
}

tests/cases/user/bluebird/tsconfig.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,5 +10,5 @@
1010
"types": ["node"],
1111
"lib": ["esnext", "dom"],
1212
},
13-
"include": ["node_modules/bluebird"]
13+
"include": ["node_modules/bluebird/js/release"]
1414
}

tests/cases/user/lodash/tsconfig.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,5 +10,6 @@
1010
"types": ["node"],
1111
"lib": ["esnext", "dom"],
1212
},
13-
"include": ["node_modules/lodash"]
13+
"include": ["node_modules/lodash"],
14+
"exclude": ["node_modules/lodash/lodash.js"]
1415
}

tests/cases/user/url-search-params/tsconfig.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,5 +10,5 @@
1010
"types": ["node"],
1111
"lib": ["esnext", "dom"],
1212
},
13-
"include": ["node_modules/url-search-params"]
13+
"include": ["node_modules/url-search-params/build/url-search-params.node.js"]
1414
}

0 commit comments

Comments
 (0)