From 13db718bda3ff6cf7878af1edd53979ddbfe11a8 Mon Sep 17 00:00:00 2001 From: Byron Gamatos Date: Thu, 2 Jul 2026 14:03:05 +0200 Subject: [PATCH] =?UTF-8?q?test(v3):=20sync=20A=E2=80=93Z=20rail=20asserti?= =?UTF-8?q?on=20to=20the=20railParams=20refactor=20(#702)=20(#714)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit refreshRail was refactored (PR #702 work-grouping) to build a `railParams = { sort_letters: 1 }` object (adding group when grouping is active) before calling queryParams(), instead of the inline queryParams({ sort_letters: 1 }). Behaviour is unchanged — it still opts into the active-sort breakdown — but the source-assertion test lagged and went red on main. Point the assertion at the new railParams shape. Co-authored-by: Claude Opus 4.8 (1M context) --- tests/js/v3_az_rail.test.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/js/v3_az_rail.test.js b/tests/js/v3_az_rail.test.js index dde612d..b8fa91b 100644 --- a/tests/js/v3_az_rail.test.js +++ b/tests/js/v3_az_rail.test.js @@ -44,7 +44,7 @@ test('refreshRail reads present letters from the stats endpoint (sort-aware)', ( assert.match(src, /\/api\/library\/stats\?'\s*\+\s*queryParams/, 'refreshRail must query /api/library/stats with the active filter params'); // Opts into the active-sort breakdown so non-rail callers skip the scan. - assert.match(src, /queryParams\(\{\s*sort_letters:\s*1\s*\}\)/, + assert.match(src, /railParams\s*=\s*\{\s*sort_letters:\s*1\s*\}/, 'refreshRail must request the sort_letters breakdown'); assert.match(src, /letters\s*=\s*stats\s*&&\s*stats\.sort_letters/, 'refreshRail must prefer the active-sort breakdown (sort_letters)');