getStoredMermaidRenderer assumed localStorage always exists whenever window was defined, so full bun test runs could fail after other suites stubbed a partial window. Safe-read the storage key and clean up shared window mocks so Verify update stays green for forked deployments.