From ca91573b46dd5dd732e1e32747540d8c00020d67 Mon Sep 17 00:00:00 2001 From: chansuke Date: Thu, 6 Jun 2024 22:30:54 +0900 Subject: [PATCH 1/2] fix(use-adjacent-overload-signature): update snapshot for latest logic --- .../invalid.ts.snap | 24 +++++++++---------- 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/crates/biome_js_analyze/tests/specs/nursery/useAdjacentOverloadSignatures/invalid.ts.snap b/crates/biome_js_analyze/tests/specs/nursery/useAdjacentOverloadSignatures/invalid.ts.snap index 7456848a8131..0376649de47b 100644 --- a/crates/biome_js_analyze/tests/specs/nursery/useAdjacentOverloadSignatures/invalid.ts.snap +++ b/crates/biome_js_analyze/tests/specs/nursery/useAdjacentOverloadSignatures/invalid.ts.snap @@ -50,12 +50,12 @@ class C { } class D { - fooB(s: string): void; - fooB(s: string): void; - barB(): void {}; - fooB(n: number): void; - fooB(sn: string | number): void {}; - fooB(sn: string | number): void {}; + fooD(s: string): void; + fooD(s: string): void; + barD(): void {}; + fooD(n: number): void; + fooD(sn: string | number): void {}; + fooD(sn: string | number): void {}; } export function foo(s: string): void; @@ -200,14 +200,14 @@ invalid.ts:40:3 lint/nursery/useAdjacentOverloadSignatures ━━━━━━━ ``` invalid.ts:50:3 lint/nursery/useAdjacentOverloadSignatures ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ - ! All fooB signatures must be adjacent. + ! All fooD signatures must be adjacent. - 48 │ fooB(s: string): void; - 49 │ barB(): void {}; - > 50 │ fooB(n: number): void; + 48 │ fooD(s: string): void; + 49 │ barD(): void {}; + > 50 │ fooD(n: number): void; │ ^^^^ - 51 │ fooB(sn: string | number): void {}; - 52 │ fooB(sn: string | number): void {}; + 51 │ fooD(sn: string | number): void {}; + 52 │ fooD(sn: string | number): void {}; ``` From 9a84926d60dcac8571a081cd6f56fc122f370d3e Mon Sep 17 00:00:00 2001 From: chansuke Date: Thu, 6 Jun 2024 22:33:04 +0900 Subject: [PATCH 2/2] chore(use-adjacent-overload-signature): update method name --- .../nursery/useAdjacentOverloadSignatures/invalid.ts | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/crates/biome_js_analyze/tests/specs/nursery/useAdjacentOverloadSignatures/invalid.ts b/crates/biome_js_analyze/tests/specs/nursery/useAdjacentOverloadSignatures/invalid.ts index 5a357bb9a476..81bb187ded74 100644 --- a/crates/biome_js_analyze/tests/specs/nursery/useAdjacentOverloadSignatures/invalid.ts +++ b/crates/biome_js_analyze/tests/specs/nursery/useAdjacentOverloadSignatures/invalid.ts @@ -44,12 +44,12 @@ class C { } class D { - fooB(s: string): void; - fooB(s: string): void; - barB(): void {}; - fooB(n: number): void; - fooB(sn: string | number): void {}; - fooB(sn: string | number): void {}; + fooD(s: string): void; + fooD(s: string): void; + barD(): void {}; + fooD(n: number): void; + fooD(sn: string | number): void {}; + fooD(sn: string | number): void {}; } export function foo(s: string): void;