Skip to content

Commit ea48ded

Browse files
authored
Shrink relationComplexityError test size (#62754)
1 parent 0f766a9 commit ea48ded

File tree

4 files changed

+10
-10
lines changed

4 files changed

+10
-10
lines changed

tests/baselines/reference/relationComplexityError.errors.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ relationComplexityError.ts(12,5): error TS2859: Excessive complexity comparing t
55
==== relationComplexityError.ts (2 errors) ====
66
// Repro from #55630
77

8-
type Digits = '0' | '1' | '2' | '3' | '4' | '5' | '6' | '7' | '8' | '9';
8+
type Digits = '0' | '1' | '2' | '3' | '4' | '5' | '6' | '7';
99
type T1 = `${Digits}${Digits}${Digits}${Digits}` | undefined;
1010
type T2 = { a: string } | { b: number };
1111

tests/baselines/reference/relationComplexityError.symbols

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,11 @@
33
=== relationComplexityError.ts ===
44
// Repro from #55630
55

6-
type Digits = '0' | '1' | '2' | '3' | '4' | '5' | '6' | '7' | '8' | '9';
6+
type Digits = '0' | '1' | '2' | '3' | '4' | '5' | '6' | '7';
77
>Digits : Symbol(Digits, Decl(relationComplexityError.ts, 0, 0))
88

99
type T1 = `${Digits}${Digits}${Digits}${Digits}` | undefined;
10-
>T1 : Symbol(T1, Decl(relationComplexityError.ts, 2, 72))
10+
>T1 : Symbol(T1, Decl(relationComplexityError.ts, 2, 60))
1111
>Digits : Symbol(Digits, Decl(relationComplexityError.ts, 0, 0))
1212
>Digits : Symbol(Digits, Decl(relationComplexityError.ts, 0, 0))
1313
>Digits : Symbol(Digits, Decl(relationComplexityError.ts, 0, 0))
@@ -21,9 +21,9 @@ type T2 = { a: string } | { b: number };
2121
function f1(x: T1, y: T1 & T2) {
2222
>f1 : Symbol(f1, Decl(relationComplexityError.ts, 4, 40))
2323
>x : Symbol(x, Decl(relationComplexityError.ts, 6, 12))
24-
>T1 : Symbol(T1, Decl(relationComplexityError.ts, 2, 72))
24+
>T1 : Symbol(T1, Decl(relationComplexityError.ts, 2, 60))
2525
>y : Symbol(y, Decl(relationComplexityError.ts, 6, 18))
26-
>T1 : Symbol(T1, Decl(relationComplexityError.ts, 2, 72))
26+
>T1 : Symbol(T1, Decl(relationComplexityError.ts, 2, 60))
2727
>T2 : Symbol(T2, Decl(relationComplexityError.ts, 3, 61))
2828

2929
x = y;
@@ -34,9 +34,9 @@ function f1(x: T1, y: T1 & T2) {
3434
function f2(x: T1 | null, y: T1 & T2) {
3535
>f2 : Symbol(f2, Decl(relationComplexityError.ts, 8, 1))
3636
>x : Symbol(x, Decl(relationComplexityError.ts, 10, 12))
37-
>T1 : Symbol(T1, Decl(relationComplexityError.ts, 2, 72))
37+
>T1 : Symbol(T1, Decl(relationComplexityError.ts, 2, 60))
3838
>y : Symbol(y, Decl(relationComplexityError.ts, 10, 25))
39-
>T1 : Symbol(T1, Decl(relationComplexityError.ts, 2, 72))
39+
>T1 : Symbol(T1, Decl(relationComplexityError.ts, 2, 60))
4040
>T2 : Symbol(T2, Decl(relationComplexityError.ts, 3, 61))
4141

4242
x = y; // Complexity error

tests/baselines/reference/relationComplexityError.types

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,12 @@
22

33
=== Performance Stats ===
44
Assignability cache: 2,500,000
5-
Type Count: 25,000
5+
Type Count: 10,000
66

77
=== relationComplexityError.ts ===
88
// Repro from #55630
99

10-
type Digits = '0' | '1' | '2' | '3' | '4' | '5' | '6' | '7' | '8' | '9';
10+
type Digits = '0' | '1' | '2' | '3' | '4' | '5' | '6' | '7';
1111
>Digits : Digits
1212
> : ^^^^^^
1313

tests/cases/compiler/relationComplexityError.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
// Repro from #55630
55

6-
type Digits = '0' | '1' | '2' | '3' | '4' | '5' | '6' | '7' | '8' | '9';
6+
type Digits = '0' | '1' | '2' | '3' | '4' | '5' | '6' | '7';
77
type T1 = `${Digits}${Digits}${Digits}${Digits}` | undefined;
88
type T2 = { a: string } | { b: number };
99

0 commit comments

Comments
 (0)