Skip to content

Commit 6f341ce

Browse files
kalvinnchauhax
andauthored
fix(bestie): stub page navigation position in PinnedBestie test (#2169)
## Problem `main` CI is red: all four `JavaScript (n/4)` jobs fail at `tsc --noEmit` (e.g. run 41491229758 on `baeefef1e`): ``` src/bundled/bestie/PinnedBestie.test.tsx(560,11): error TS2739: ... is missing the following properties from type 'PageNavigation': position, savePosition ``` ## Cause Semantic merge conflict between two PRs that were each green on their own: - #1960 (`dd898a7c6`) made `position(key)` and `savePosition(key, value)` required members of `PageNavigation` (`src/features/navigation/service.ts`) so pages can restore the reader's place on Back. - #1935 (`baeefef1e`, pin the saved Bestie DM) added a hand-built `PageNavigation` stub in `PinnedBestie.test.tsx` that was written against the older shape. ## Fix Add `position: () => undefined` and `savePosition() {}` to the stub. This is the same no-op stub used by the other page tests (e.g. `src/bundled/agents/AgentsPage.test.tsx:678`). Test-only change, no production code touched. Pinned Bestie doesn't use saved positions, so a no-op stub keeps the test's behavior as-is. ## Validation - `bin/pnpm exec tsc --noEmit`: clean - `bin/pnpm exec vitest run src/bundled/bestie/PinnedBestie.test.tsx`: 14/14 pass - Pre-commit hooks (biome, icons, literal-names, sadscan) pass Not run locally: the full Vitest shards and browser suites. This PR's CI covers those. Signed-off-by: Kalvin Chau <[email protected]> Co-authored-by: hax <[email protected]>
1 parent a4cc3ce commit 6f341ce

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

‎src/bundled/bestie/PinnedBestie.test.tsx‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -562,6 +562,8 @@ async function threadHistoryFixture() {
562562
target: entry.target,
563563
signal: attempt.signal,
564564
...(attempt.focus ? { focus: attempt.focus } : {}),
565+
position: () => undefined,
566+
savePosition() {},
565567
forSession: () => request,
566568
resolve: () => false,
567569
complete: () => true,

0 commit comments

Comments
 (0)