From ab5e89f10a34b88bc8a5af2ec71f308dbc3af8e7 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Fri, 6 Feb 2026 06:12:38 +0000 Subject: [PATCH] Revert eslint changes and assign test result to variable Co-authored-by: jakebailey <5341706+jakebailey@users.noreply.github.com> --- src/harness/harnessGlobals.ts | 4 ++-- .../reference/intlNumberFormatES2023.js | 4 ++-- .../reference/intlNumberFormatES2023.symbols | 3 ++- .../reference/intlNumberFormatES2023.types | 4 +++- .../es2023/intlNumberFormatES2023.ts | 22 +++++++++---------- 5 files changed, 20 insertions(+), 17 deletions(-) diff --git a/src/harness/harnessGlobals.ts b/src/harness/harnessGlobals.ts index 87831e80f66..05193e79f17 100644 --- a/src/harness/harnessGlobals.ts +++ b/src/harness/harnessGlobals.ts @@ -5,11 +5,11 @@ import * as ts from "./_namespaces/ts.js"; // this will work in the browser via browserify declare global { // Module transform: converted from ambient declaration - var assert: typeof chai.assert; // eslint-disable-line no-var + var assert: typeof chai.assert; } declare global { // Module transform: converted from ambient declaration - var expect: typeof chai.expect; // eslint-disable-line no-var + var expect: typeof chai.expect; } globalThis.assert = chai.assert; { diff --git a/tests/baselines/reference/intlNumberFormatES2023.js b/tests/baselines/reference/intlNumberFormatES2023.js index 788f4fd755a..e8af110f8af 100644 --- a/tests/baselines/reference/intlNumberFormatES2023.js +++ b/tests/baselines/reference/intlNumberFormatES2023.js @@ -39,7 +39,7 @@ const nf = new Intl.NumberFormat("en-US", { maximumFractionDigits: 0, }); -nf +const filtered = nf .formatRangeToParts(100, 100) .filter((part) => part.type !== "approximatelySign") .map((part) => part.value) @@ -78,7 +78,7 @@ const nf = new Intl.NumberFormat("en-US", { currency: "EUR", maximumFractionDigits: 0, }); -nf +const filtered = nf .formatRangeToParts(100, 100) .filter((part) => part.type !== "approximatelySign") .map((part) => part.value) diff --git a/tests/baselines/reference/intlNumberFormatES2023.symbols b/tests/baselines/reference/intlNumberFormatES2023.symbols index c9657d57e65..79a196aa972 100644 --- a/tests/baselines/reference/intlNumberFormatES2023.symbols +++ b/tests/baselines/reference/intlNumberFormatES2023.symbols @@ -148,7 +148,8 @@ const nf = new Intl.NumberFormat("en-US", { }); -nf +const filtered = nf +>filtered : Symbol(filtered, Decl(intlNumberFormatES2023.ts, 38, 5)) >nf .formatRangeToParts(100, 100) .filter((part) => part.type !== "approximatelySign") .map((part) => part.value) .join : Symbol(Array.join, Decl(lib.es5.d.ts, --, --)) >nf .formatRangeToParts(100, 100) .filter((part) => part.type !== "approximatelySign") .map : Symbol(Array.map, Decl(lib.es5.d.ts, --, --)) >nf .formatRangeToParts(100, 100) .filter : Symbol(Array.filter, Decl(lib.es5.d.ts, --, --), Decl(lib.es5.d.ts, --, --)) diff --git a/tests/baselines/reference/intlNumberFormatES2023.types b/tests/baselines/reference/intlNumberFormatES2023.types index a05fed5f24e..3b9017e0c6b 100644 --- a/tests/baselines/reference/intlNumberFormatES2023.types +++ b/tests/baselines/reference/intlNumberFormatES2023.types @@ -413,7 +413,9 @@ const nf = new Intl.NumberFormat("en-US", { }); -nf +const filtered = nf +>filtered : string +> : ^^^^^^ >nf .formatRangeToParts(100, 100) .filter((part) => part.type !== "approximatelySign") .map((part) => part.value) .join("") : string > : ^^^^^^ >nf .formatRangeToParts(100, 100) .filter((part) => part.type !== "approximatelySign") .map((part) => part.value) .join : (separator?: string) => string diff --git a/tests/cases/conformance/es2023/intlNumberFormatES2023.ts b/tests/cases/conformance/es2023/intlNumberFormatES2023.ts index a2f7c282baf..b8c13428491 100644 --- a/tests/cases/conformance/es2023/intlNumberFormatES2023.ts +++ b/tests/cases/conformance/es2023/intlNumberFormatES2023.ts @@ -33,15 +33,15 @@ new Intl.NumberFormat('en-GB').format('Infinity'); new Intl.NumberFormat('en-GB').format('-Infinity'); new Intl.NumberFormat('en-GB').format('+Infinity'); -// Test approximatelySign part type -const nf = new Intl.NumberFormat("en-US", { - style: "currency", - currency: "EUR", - maximumFractionDigits: 0, -}); - -nf - .formatRangeToParts(100, 100) - .filter((part) => part.type !== "approximatelySign") - .map((part) => part.value) +// Test approximatelySign part type +const nf = new Intl.NumberFormat("en-US", { + style: "currency", + currency: "EUR", + maximumFractionDigits: 0, +}); + +const filtered = nf + .formatRangeToParts(100, 100) + .filter((part) => part.type !== "approximatelySign") + .map((part) => part.value) .join("");