From 46ae79dbe7a0fb64aff9bdcc76eadafd75e10c9e Mon Sep 17 00:00:00 2001 From: hided62 Date: Sat, 25 Jul 2026 06:50:41 +0000 Subject: [PATCH] test: allow strict battle parity diagnostics --- tools/integration-tests/test/battleDifferential.test.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tools/integration-tests/test/battleDifferential.test.ts b/tools/integration-tests/test/battleDifferential.test.ts index cd80908..03a9575 100644 --- a/tools/integration-tests/test/battleDifferential.test.ts +++ b/tools/integration-tests/test/battleDifferential.test.ts @@ -127,6 +127,10 @@ const runReferenceItemCatalog = (workspaceRoot: string, itemKeys: string[]): Rec const expectNearlyEqual = (actual: unknown, expected: unknown, label: string): void => { expect(typeof actual, `${label}: actual type`).toBe('number'); expect(typeof expected, `${label}: reference type`).toBe('number'); + if (process.env['STRICT_BATTLE_PARITY'] === '1') { + expect(actual, `${label}: exact battle parity`).toBe(expected); + return; + } const reference = expected as number; const tolerance = Math.max(1, Math.abs(reference) * 0.01); expect(