platform-clang-runtime: 2 curriculum-pane specs fail on master (localStorage.getItem is not a function) #723

Closed
opened 2026-07-19 15:34:53 +00:00 by spikerj · 1 comment
Owner

language-playground-shell.component.spec.ts — "persists the progress choice and restores it on the next mount" and "keeps the default when a legacy blob lacks the field or carries garbage" both fail with TypeError: localStorage.getItem/setItem is not a function.

Verified pre-existing on clean master (2026-07-19, during epic #722 E0 verification — unrelated to that PR). Looks like a stubbed/clobbered localStorage global leaking between specs in this project (another spec in the same project probably replaces globalThis.localStorage with a non-Storage object and doesn't restore it), since jsdom normally provides a working localStorage.

Repro: pnpm nx run platform-clang-runtime:test --skip-nx-cache → 1 file failed (2 tests), 5 passed.

`language-playground-shell.component.spec.ts` — "persists the progress choice and restores it on the next mount" and "keeps the default when a legacy blob lacks the field or carries garbage" both fail with `TypeError: localStorage.getItem/setItem is not a function`. Verified pre-existing on clean master (2026-07-19, during epic #722 E0 verification — unrelated to that PR). Looks like a stubbed/clobbered `localStorage` global leaking between specs in this project (another spec in the same project probably replaces `globalThis.localStorage` with a non-Storage object and doesn't restore it), since jsdom normally provides a working localStorage. Repro: `pnpm nx run platform-clang-runtime:test --skip-nx-cache` → 1 file failed (2 tests), 5 passed.
Author
Owner

Verified complete: spikersoft-angular PR #457 merged (shared in-memory storage setup for the playground persistence specs); master test-and-lint has run green repeatedly since. Closing.

Verified complete: spikersoft-angular PR #457 merged (shared in-memory storage setup for the playground persistence specs); master test-and-lint has run green repeatedly since. Closing.
Sign in to join this conversation.