Files
SubMiner/backlog/tasks/task-87.3 - Immersion-tracking-verification-make-SQLite-backed-persistence-tests-visible-and-reproducible.md

2.3 KiB

id, title, status, assignee, created_date, updated_date, labels, milestone, dependencies, references, documentation, parent_task_id, priority
id title status assignee created_date updated_date labels milestone dependencies references documentation parent_task_id priority
TASK-87.3 Immersion tracking verification: make SQLite-backed persistence tests visible and reproducible To Do
2026-03-06 03:19 2026-03-06 03:21
tests
immersion-tracking
m-0
src/core/services/immersion-tracker-service.test.ts
src/core/services/immersion-tracker/storage-session.test.ts
src/core/services/immersion-tracker-service.ts
package.json
docs/reports/2026-02-22-task-100-dead-code-report.md
TASK-87 medium

Description

The immersion tracker is persistence-heavy, but its SQLite-backed tests are conditionally skipped in the standard Bun run when node:sqlite support is unavailable. That creates a blind spot around session finalization, telemetry persistence, and retention behavior. This task should establish a reliable automated verification path for the database-backed cases and make the prerequisite/runtime behavior explicit to contributors and CI.

Acceptance Criteria

  • #1 Database-backed immersion tracking tests run in at least one documented automated command that is practical for contributors or CI to execute.
  • #2 If the current runtime cannot execute the SQLite-backed tests, the repository exposes that limitation clearly instead of silently reporting a misleading green result.
  • #3 Contributor-facing documentation explains how to run the immersion tracker verification lane and any environment prerequisites it depends on.
  • #4 The resulting verification covers session persistence or finalization behavior that is not exercised by the pure seam tests alone.

Implementation Plan

  1. Confirm which SQLite-backed immersion tests are currently skipped and why in the standard Bun environment.
  2. Establish a reproducible command or lane for the DB-backed cases, or make the unsupported-runtime limitation explicit and actionable.
  3. Document prerequisites and expected behavior for contributors and CI.
  4. Verify at least one persistence/finalization path beyond the seam tests is exercised by the new lane.