starbasedb icon indicating copy to clipboard operation
starbasedb copied to clipboard

test: cover auth template entrypoint

Open Treasure520520 opened this issue 6 months ago • 0 comments

Summary

  • Adds focused Vitest coverage for templates/auth/src/index.ts.
  • Covers the unnamed fetch 404, auth route dispatch to signup/login/logout, unsupported route 405, logout session invalidation SQL, and isSessionValid true/false paths.
  • Keeps this slice non-overlapping with #182, which covers auth utils and email signup/login handler behavior.

Refs #71 /claim #71

Tests

  • COREPACK_ENABLE_PROJECT_SPEC=0 corepack pnpm vitest --run templates/auth/src/index.test.ts -> 7 tests passed
  • COREPACK_ENABLE_PROJECT_SPEC=0 corepack pnpm prettier --check templates/auth/src/index.test.ts -> passed
  • git diff --check -> passed

Transparency: AI-assisted with Codex; I reviewed the diff and kept the PR scoped to auth-template entrypoint coverage.

Treasure520520 avatar May 12 '26 21:05 Treasure520520