Problem
The "throw when branchName missing" test in src/app/sandbox/hooks/useGitHub.test.ts is broken and currently .skipped. The test expects the hook to throw when branchName is missing, but the current source returns null instead — so the assertion fails.
Like the other skipped test, this was already failing on main and only surfaced because unit suites weren't run in CI. It was marked .skip (not deleted) during the Jest→Vitest migration (#45 / PR #46). With CI now running the suites (#33 / PR #47), the mismatch should be resolved.
Task
Decide which behavior is correct and align the two:
- If throwing is correct (missing
branchName is a programmer error): update the source to throw and keep/adjust the test.
- If returning
null is correct (graceful no-op): update the test to assert the null/no-op behavior and rename it accordingly.
Then remove the .skip and confirm it passes under pnpm test:web.
Acceptance criteria
References
Problem
The "throw when branchName missing" test in
src/app/sandbox/hooks/useGitHub.test.tsis broken and currently.skipped. The test expects the hook to throw whenbranchNameis missing, but the current source returnsnullinstead — so the assertion fails.Like the other skipped test, this was already failing on
mainand only surfaced because unit suites weren't run in CI. It was marked.skip(not deleted) during the Jest→Vitest migration (#45 / PR #46). With CI now running the suites (#33 / PR #47), the mismatch should be resolved.Task
Decide which behavior is correct and align the two:
branchNameis a programmer error): update the source to throw and keep/adjust the test.nullis correct (graceful no-op): update the test to assert thenull/no-op behavior and rename it accordingly.Then remove the
.skipand confirm it passes underpnpm test:web.Acceptance criteria
branchNamecontract, and the decision is intentionalpnpm test:webgreenReferences
src/app/sandbox/hooks/useGitHub.test.ts