Skip to content

Commit a009ee1

Browse files
committed
Accept new baselines
1 parent 628da10 commit a009ee1

23 files changed

+134
-414
lines changed

tests/baselines/reference/checkJsxChildrenProperty4.errors.txt

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
tests/cases/conformance/jsx/file.tsx(24,28): error TS2551: Property 'NAme' does not exist on type 'IUser'. Did you mean 'Name'?
22
tests/cases/conformance/jsx/file.tsx(36,15): error TS2322: Type '(user: IUser) => Element' is not assignable to type 'boolean | any[] | ReactChild'.
3-
Type '(user: IUser) => Element' is missing the following properties from type 'ReactElement<any>': type, props
43
tests/cases/conformance/jsx/file.tsx(39,15): error TS2322: Type '(user: IUser) => Element' is not assignable to type 'boolean | any[] | ReactChild'.
5-
Type '(user: IUser) => Element' is missing the following properties from type 'ReactElement<any>': type, props
64

75

86
==== tests/cases/conformance/jsx/file.tsx (3 errors) ====
@@ -51,7 +49,6 @@ tests/cases/conformance/jsx/file.tsx(39,15): error TS2322: Type '(user: IUser) =
5149
) }
5250
~~~~~~~~~~~~~
5351
!!! error TS2322: Type '(user: IUser) => Element' is not assignable to type 'boolean | any[] | ReactChild'.
54-
!!! error TS2322: Type '(user: IUser) => Element' is missing the following properties from type 'ReactElement<any>': type, props
5552
!!! related TS6212 tests/cases/conformance/jsx/file.tsx:36:15: Did you mean to call this expression?
5653
{ user => (
5754
~~~~~~~~~
@@ -60,7 +57,6 @@ tests/cases/conformance/jsx/file.tsx(39,15): error TS2322: Type '(user: IUser) =
6057
) }
6158
~~~~~~~~~~~~~
6259
!!! error TS2322: Type '(user: IUser) => Element' is not assignable to type 'boolean | any[] | ReactChild'.
63-
!!! error TS2322: Type '(user: IUser) => Element' is missing the following properties from type 'ReactElement<any>': type, props
6460
!!! related TS6212 tests/cases/conformance/jsx/file.tsx:39:15: Did you mean to call this expression?
6561
</FetchUser>
6662
);

tests/baselines/reference/circularlyConstrainedMappedTypeContainingConditionalNoInfiniteInstantiationDepth.errors.txt

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

tests/baselines/reference/complicatedIndexedAccessKeyofReliesOnKeyofNeverUpperBound.errors.txt

Lines changed: 18 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -2,21 +2,16 @@ tests/cases/compiler/complicatedIndexedAccessKeyofReliesOnKeyofNeverUpperBound.t
22
Type '{ type: T; localChannelId: string; }' is not assignable to type 'Pick<ChannelOfType<T, TextChannel> | ChannelOfType<T, EmailChannel>, "type">'.
33
Types of property 'type' are incompatible.
44
Type 'T' is not assignable to type 'ChannelOfType<T, TextChannel>["type"] & ChannelOfType<T, EmailChannel>["type"]'.
5-
Type '"text" | "email"' is not assignable to type 'ChannelOfType<T, TextChannel>["type"] & ChannelOfType<T, EmailChannel>["type"]'.
6-
Type '"text"' is not assignable to type 'ChannelOfType<T, TextChannel>["type"] & ChannelOfType<T, EmailChannel>["type"]'.
5+
Type 'T' is not assignable to type 'ChannelOfType<T, TextChannel>["type"]'.
6+
Type '"text" | "email"' is not assignable to type 'ChannelOfType<T, TextChannel>["type"]'.
77
Type '"text"' is not assignable to type 'ChannelOfType<T, TextChannel>["type"]'.
8-
Type 'T' is not assignable to type 'ChannelOfType<T, TextChannel>["type"]'.
9-
Type '"text" | "email"' is not assignable to type 'ChannelOfType<T, TextChannel>["type"]'.
10-
Type '"text"' is not assignable to type 'ChannelOfType<T, TextChannel>["type"]'.
11-
Type '"text"' is not assignable to type 'T & "text"'.
12-
Type 'T' is not assignable to type 'T & "text"'.
13-
Type '"text" | "email"' is not assignable to type 'T & "text"'.
14-
Type '"text"' is not assignable to type 'T & "text"'.
15-
Type '"text"' is not assignable to type 'T'.
16-
'"text"' is assignable to the constraint of type 'T', but 'T' could be instantiated with a different subtype of constraint '"text" | "email"'.
17-
Type 'T' is not assignable to type '"text"'.
18-
Type '"text" | "email"' is not assignable to type '"text"'.
19-
Type '"email"' is not assignable to type '"text"'.
8+
Type '"text"' is not assignable to type 'T & "text"'.
9+
Type '"text"' is not assignable to type 'T'.
10+
'"text"' is assignable to the constraint of type 'T', but 'T' could be instantiated with a different subtype of constraint '"text" | "email"'.
11+
Type 'T' is not assignable to type 'T & "text"'.
12+
Type 'T' is not assignable to type '"text"'.
13+
Type '"text" | "email"' is not assignable to type '"text"'.
14+
Type '"email"' is not assignable to type '"text"'.
2015

2116

2217
==== tests/cases/compiler/complicatedIndexedAccessKeyofReliesOnKeyofNeverUpperBound.ts (1 errors) ====
@@ -58,21 +53,16 @@ tests/cases/compiler/complicatedIndexedAccessKeyofReliesOnKeyofNeverUpperBound.t
5853
!!! error TS2322: Type '{ type: T; localChannelId: string; }' is not assignable to type 'Pick<ChannelOfType<T, TextChannel> | ChannelOfType<T, EmailChannel>, "type">'.
5954
!!! error TS2322: Types of property 'type' are incompatible.
6055
!!! error TS2322: Type 'T' is not assignable to type 'ChannelOfType<T, TextChannel>["type"] & ChannelOfType<T, EmailChannel>["type"]'.
61-
!!! error TS2322: Type '"text" | "email"' is not assignable to type 'ChannelOfType<T, TextChannel>["type"] & ChannelOfType<T, EmailChannel>["type"]'.
62-
!!! error TS2322: Type '"text"' is not assignable to type 'ChannelOfType<T, TextChannel>["type"] & ChannelOfType<T, EmailChannel>["type"]'.
56+
!!! error TS2322: Type 'T' is not assignable to type 'ChannelOfType<T, TextChannel>["type"]'.
57+
!!! error TS2322: Type '"text" | "email"' is not assignable to type 'ChannelOfType<T, TextChannel>["type"]'.
6358
!!! error TS2322: Type '"text"' is not assignable to type 'ChannelOfType<T, TextChannel>["type"]'.
64-
!!! error TS2322: Type 'T' is not assignable to type 'ChannelOfType<T, TextChannel>["type"]'.
65-
!!! error TS2322: Type '"text" | "email"' is not assignable to type 'ChannelOfType<T, TextChannel>["type"]'.
66-
!!! error TS2322: Type '"text"' is not assignable to type 'ChannelOfType<T, TextChannel>["type"]'.
67-
!!! error TS2322: Type '"text"' is not assignable to type 'T & "text"'.
68-
!!! error TS2322: Type 'T' is not assignable to type 'T & "text"'.
69-
!!! error TS2322: Type '"text" | "email"' is not assignable to type 'T & "text"'.
70-
!!! error TS2322: Type '"text"' is not assignable to type 'T & "text"'.
71-
!!! error TS2322: Type '"text"' is not assignable to type 'T'.
72-
!!! error TS2322: '"text"' is assignable to the constraint of type 'T', but 'T' could be instantiated with a different subtype of constraint '"text" | "email"'.
73-
!!! error TS2322: Type 'T' is not assignable to type '"text"'.
74-
!!! error TS2322: Type '"text" | "email"' is not assignable to type '"text"'.
75-
!!! error TS2322: Type '"email"' is not assignable to type '"text"'.
59+
!!! error TS2322: Type '"text"' is not assignable to type 'T & "text"'.
60+
!!! error TS2322: Type '"text"' is not assignable to type 'T'.
61+
!!! error TS2322: '"text"' is assignable to the constraint of type 'T', but 'T' could be instantiated with a different subtype of constraint '"text" | "email"'.
62+
!!! error TS2322: Type 'T' is not assignable to type 'T & "text"'.
63+
!!! error TS2322: Type 'T' is not assignable to type '"text"'.
64+
!!! error TS2322: Type '"text" | "email"' is not assignable to type '"text"'.
65+
!!! error TS2322: Type '"email"' is not assignable to type '"text"'.
7666
}
7767

7868
const newTextChannel = makeNewChannel('text');

tests/baselines/reference/conditionalTypes2.errors.txt

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,6 @@ tests/cases/conformance/types/conditional/conditionalTypes2.ts(24,5): error TS23
1717
Type 'keyof B' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf"'.
1818
Type 'string | number | symbol' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf"'.
1919
Type 'string' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf"'.
20-
Type 'keyof B' is not assignable to type 'number'.
21-
Type 'string | number | symbol' is not assignable to type 'number'.
22-
Type 'string' is not assignable to type 'number'.
2320
tests/cases/conformance/types/conditional/conditionalTypes2.ts(25,5): error TS2322: Type 'Invariant<A>' is not assignable to type 'Invariant<B>'.
2421
Types of property 'foo' are incompatible.
2522
Type 'A extends string ? keyof A : A' is not assignable to type 'B extends string ? keyof B : B'.
@@ -85,9 +82,6 @@ tests/cases/conformance/types/conditional/conditionalTypes2.ts(75,12): error TS2
8582
!!! error TS2322: Type 'keyof B' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf"'.
8683
!!! error TS2322: Type 'string | number | symbol' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf"'.
8784
!!! error TS2322: Type 'string' is not assignable to type 'number | "toString" | "charAt" | "charCodeAt" | "concat" | "indexOf" | "lastIndexOf" | "localeCompare" | "match" | "replace" | "search" | "slice" | "split" | "substring" | "toLowerCase" | "toLocaleLowerCase" | "toUpperCase" | "toLocaleUpperCase" | "trim" | "length" | "substr" | "valueOf"'.
88-
!!! error TS2322: Type 'keyof B' is not assignable to type 'number'.
89-
!!! error TS2322: Type 'string | number | symbol' is not assignable to type 'number'.
90-
!!! error TS2322: Type 'string' is not assignable to type 'number'.
9185
b = a; // Error
9286
~
9387
!!! error TS2322: Type 'Invariant<A>' is not assignable to type 'Invariant<B>'.

tests/baselines/reference/constructBigint.errors.txt

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
tests/cases/conformance/es2020/constructBigint.ts(6,8): error TS2345: Argument of type 'symbol' is not assignable to parameter of type 'string | number | bigint | boolean'.
22
tests/cases/conformance/es2020/constructBigint.ts(7,8): error TS2345: Argument of type '{ e: number; m: number; }' is not assignable to parameter of type 'string | number | bigint | boolean'.
3-
Type '{ e: number; m: number; }' is not assignable to type 'true'.
43
tests/cases/conformance/es2020/constructBigint.ts(8,8): error TS2345: Argument of type 'null' is not assignable to parameter of type 'string | number | bigint | boolean'.
54
tests/cases/conformance/es2020/constructBigint.ts(9,8): error TS2345: Argument of type 'undefined' is not assignable to parameter of type 'string | number | bigint | boolean'.
65

@@ -17,7 +16,6 @@ tests/cases/conformance/es2020/constructBigint.ts(9,8): error TS2345: Argument o
1716
BigInt({ e: 1, m: 1 })
1817
~~~~~~~~~~~~~~
1918
!!! error TS2345: Argument of type '{ e: number; m: number; }' is not assignable to parameter of type 'string | number | bigint | boolean'.
20-
!!! error TS2345: Type '{ e: number; m: number; }' is not assignable to type 'true'.
2119
BigInt(null);
2220
~~~~
2321
!!! error TS2345: Argument of type 'null' is not assignable to parameter of type 'string | number | bigint | boolean'.
Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
tests/cases/conformance/decorators/class/method/decoratorOnClassMethod8.ts(4,5): error TS1241: Unable to resolve signature of method decorator when called as an expression.
2-
tests/cases/conformance/decorators/class/method/decoratorOnClassMethod8.ts(4,5): error TS1241: Unable to resolve signature of method decorator when called as an expression.
3-
Type 'C' has no properties in common with type 'TypedPropertyDescriptor<() => void>'.
2+
tests/cases/conformance/decorators/class/method/decoratorOnClassMethod8.ts(4,5): error TS1269: Decorator function return type 'C' is not assignable to type 'void | TypedPropertyDescriptor<() => void>'.
43

54

65
==== tests/cases/conformance/decorators/class/method/decoratorOnClassMethod8.ts (2 errors) ====
@@ -11,6 +10,5 @@ tests/cases/conformance/decorators/class/method/decoratorOnClassMethod8.ts(4,5):
1110
~~~~
1211
!!! error TS1241: Unable to resolve signature of method decorator when called as an expression.
1312
~~~~
14-
!!! error TS1241: Unable to resolve signature of method decorator when called as an expression.
15-
!!! error TS1241: Type 'C' has no properties in common with type 'TypedPropertyDescriptor<() => void>'.
13+
!!! error TS1269: Decorator function return type 'C' is not assignable to type 'void | TypedPropertyDescriptor<() => void>'.
1614
}

tests/baselines/reference/destructuringObjectBindingPatternAndAssignment3.errors.txt

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
tests/cases/conformance/es6/destructuring/destructuringObjectBindingPatternAndAssignment3.ts(2,7): error TS1005: ',' expected.
22
tests/cases/conformance/es6/destructuring/destructuringObjectBindingPatternAndAssignment3.ts(3,5): error TS2322: Type '{ i: number; }' is not assignable to type 'string | number'.
3-
Type '{ i: number; }' is not assignable to type 'number'.
43
tests/cases/conformance/es6/destructuring/destructuringObjectBindingPatternAndAssignment3.ts(3,6): error TS2339: Property 'i' does not exist on type 'string | number'.
54
tests/cases/conformance/es6/destructuring/destructuringObjectBindingPatternAndAssignment3.ts(4,6): error TS2339: Property 'i1' does not exist on type 'string | number | {}'.
65
tests/cases/conformance/es6/destructuring/destructuringObjectBindingPatternAndAssignment3.ts(5,12): error TS2525: Initializer provides no value for this binding element and the binding element has no default value.
@@ -18,7 +17,6 @@ tests/cases/conformance/es6/destructuring/destructuringObjectBindingPatternAndAs
1817
var {i}: string | number = { i: 2 };
1918
~~~
2019
!!! error TS2322: Type '{ i: number; }' is not assignable to type 'string | number'.
21-
!!! error TS2322: Type '{ i: number; }' is not assignable to type 'number'.
2220
~
2321
!!! error TS2339: Property 'i' does not exist on type 'string | number'.
2422
var {i1}: string | number| {} = { i1: 2 };

tests/baselines/reference/indexedAccessRelation.errors.txt

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,8 @@
11
tests/cases/compiler/indexedAccessRelation.ts(16,23): error TS2345: Argument of type '{ a: T; }' is not assignable to parameter of type 'Pick<S & State<T>, "a">'.
22
Types of property 'a' are incompatible.
33
Type 'T' is not assignable to type 'S["a"] & T'.
4-
Type 'Foo' is not assignable to type 'S["a"] & T'.
4+
Type 'T' is not assignable to type 'S["a"]'.
55
Type 'Foo' is not assignable to type 'S["a"]'.
6-
Type 'T' is not assignable to type 'S["a"]'.
7-
Type 'Foo' is not assignable to type 'S["a"]'.
86

97

108
==== tests/cases/compiler/indexedAccessRelation.ts (1 errors) ====
@@ -28,10 +26,8 @@ tests/cases/compiler/indexedAccessRelation.ts(16,23): error TS2345: Argument of
2826
!!! error TS2345: Argument of type '{ a: T; }' is not assignable to parameter of type 'Pick<S & State<T>, "a">'.
2927
!!! error TS2345: Types of property 'a' are incompatible.
3028
!!! error TS2345: Type 'T' is not assignable to type 'S["a"] & T'.
31-
!!! error TS2345: Type 'Foo' is not assignable to type 'S["a"] & T'.
29+
!!! error TS2345: Type 'T' is not assignable to type 'S["a"]'.
3230
!!! error TS2345: Type 'Foo' is not assignable to type 'S["a"]'.
33-
!!! error TS2345: Type 'T' is not assignable to type 'S["a"]'.
34-
!!! error TS2345: Type 'Foo' is not assignable to type 'S["a"]'.
3531
}
3632
}
3733

tests/baselines/reference/inferTypes1.errors.txt

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@ tests/cases/conformance/types/conditional/inferTypes1.ts(84,43): error TS4081: E
1818
tests/cases/conformance/types/conditional/inferTypes1.ts(91,44): error TS2344: Type 'U' does not satisfy the constraint 'string'.
1919
Type 'number' is not assignable to type 'string'.
2020
tests/cases/conformance/types/conditional/inferTypes1.ts(153,40): error TS2322: Type 'T' is not assignable to type 'string | number | symbol'.
21-
Type 'T' is not assignable to type 'symbol'.
2221

2322

2423
==== tests/cases/conformance/types/conditional/inferTypes1.ts (16 errors) ====
@@ -211,7 +210,6 @@ tests/cases/conformance/types/conditional/inferTypes1.ts(153,40): error TS2322:
211210
type B<T> = string extends T ? { [P in T]: void; } : T; // Error
212211
~
213212
!!! error TS2322: Type 'T' is not assignable to type 'string | number | symbol'.
214-
!!! error TS2322: Type 'T' is not assignable to type 'symbol'.
215213

216214
// Repro from #22302
217215

tests/baselines/reference/intersectionAndUnionTypes.errors.txt

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,13 +14,11 @@ tests/cases/conformance/types/intersection/intersectionAndUnionTypes.ts(26,1): e
1414
Property 'a' is missing in type 'C & D' but required in type 'A'.
1515
tests/cases/conformance/types/intersection/intersectionAndUnionTypes.ts(27,1): error TS2322: Type '(A & B) | (C & D)' is not assignable to type 'A | B'.
1616
Type 'C & D' is not assignable to type 'A | B'.
17-
Property 'b' is missing in type 'C & D' but required in type 'B'.
1817
tests/cases/conformance/types/intersection/intersectionAndUnionTypes.ts(28,1): error TS2322: Type '(A & B) | (C & D)' is not assignable to type 'C & D'.
1918
Type 'A & B' is not assignable to type 'C & D'.
2019
Property 'c' is missing in type 'A & B' but required in type 'C'.
2120
tests/cases/conformance/types/intersection/intersectionAndUnionTypes.ts(29,1): error TS2322: Type '(A & B) | (C & D)' is not assignable to type 'C | D'.
2221
Type 'A & B' is not assignable to type 'C | D'.
23-
Property 'd' is missing in type 'A & B' but required in type 'D'.
2422
tests/cases/conformance/types/intersection/intersectionAndUnionTypes.ts(31,1): error TS2322: Type 'A & B' is not assignable to type '(A | B) & (C | D)'.
2523
Type 'A & B' is not assignable to type 'B & D'.
2624
Property 'd' is missing in type 'A & B' but required in type 'D'.
@@ -97,8 +95,6 @@ tests/cases/conformance/types/intersection/intersectionAndUnionTypes.ts(37,1): e
9795
~~~
9896
!!! error TS2322: Type '(A & B) | (C & D)' is not assignable to type 'A | B'.
9997
!!! error TS2322: Type 'C & D' is not assignable to type 'A | B'.
100-
!!! error TS2322: Property 'b' is missing in type 'C & D' but required in type 'B'.
101-
!!! related TS2728 tests/cases/conformance/types/intersection/intersectionAndUnionTypes.ts:2:15: 'b' is declared here.
10298
cnd = x;
10399
~~~
104100
!!! error TS2322: Type '(A & B) | (C & D)' is not assignable to type 'C & D'.
@@ -109,8 +105,6 @@ tests/cases/conformance/types/intersection/intersectionAndUnionTypes.ts(37,1): e
109105
~~~
110106
!!! error TS2322: Type '(A & B) | (C & D)' is not assignable to type 'C | D'.
111107
!!! error TS2322: Type 'A & B' is not assignable to type 'C | D'.
112-
!!! error TS2322: Property 'd' is missing in type 'A & B' but required in type 'D'.
113-
!!! related TS2728 tests/cases/conformance/types/intersection/intersectionAndUnionTypes.ts:4:15: 'd' is declared here.
114108

115109
y = anb;
116110
~

0 commit comments

Comments
 (0)