feat(05-05): ?fixpair harness knob + pinned-corpus origin lookup (GREEN)
- route-profiles.ts: HARNESS-ONLY module — sentinel ROUTE_PROFILE_HARNESS_ONLY + getRouteProfileOrigin wrapping getPairOrigin; D-12 header (pinned PUBLIC origin only, no coordinate params) + BA5 exclusion note - index.html: ?fixpair=<pair-id> knob resolves the pair's pinned public origin as the mock's telegramFix (accuracy 12, heading null); unknown pairId keeps the default fix; knob documented in the profile comment - [Rule 1 - Bug] main.ts never passed bootMap's opts.onLoad — route sources never existed and setRouteDrawn's setData silently no-op'd (cards rendered, the line never painted; invisible to the RS fakes). Wiring added + RS2 boot-wiring gate pins it - [Rule 1 - Bug] consult raced the map load: harness session stubs resolve the location chain before WebGL/style init, so draw landed on missing sources and the post-load empty install discarded it (probe: ROUTE token fired before RAMS-BASEMAP-READY). Consult now awaits mapLayersReady, resolved in the load handler after installRouteLayers (never wedges — finally-resolved; cards-only boots resolve immediately) - Capture run: CAPTURE OK — 13/13; route line verified painted, alt swap renders ROUTE 2/2 +1 MIN VS ROUTE 1, pending card honest, dark PX-02 - npm test -w web: 76 passed (new RS2 boot-wiring gate included)
This commit is contained in:
@@ -142,6 +142,14 @@ test("RS2 map-law — zero setStyle in web/src/route; opts.onLoad sits after bui
|
||||
assert.ok(onLoad < ready, "the route install is BEFORE the RAMS-BASEMAP-READY log — sources exist when captures wait");
|
||||
});
|
||||
|
||||
test("RS2 boot wiring — main.ts passes opts.onLoad to bootMap installing the route layers (05-05 capture fix)", () => {
|
||||
const mainCode = codeText(path.join(SRC, "main.ts"));
|
||||
assert.ok(
|
||||
/bootMap\([\s\S]{0,400}?onLoad:\s*\(m\)\s*=>[\s\S]{0,200}?installRouteLayers\(/.test(mainCode),
|
||||
"main.ts must wire bootMap's opts.onLoad to installRouteLayers — without the callback the sources never exist and setRouteDrawn's setData silently no-ops (cards render, the line never paints; found by the 05-05 capture legs)",
|
||||
);
|
||||
});
|
||||
|
||||
/* ————— RS3 — fake-map layer law ————— */
|
||||
|
||||
test("RS3 fake-map layers — 2 sources + 4 layers in order, idempotent install, setData swaps, empty clears", () => {
|
||||
|
||||
Reference in New Issue
Block a user