fix: add GitContext type annotation to mock in generate.test.ts

The mockGitContext variable was declared without a type annotation,
causing TypeScript to infer a narrow type from the initial assignment
(status: "modified"). This made reassignment with status: "added"
fail with TS2322. Adding the GitContext type allows all valid status
values.
This commit is contained in:
Mark IJbema
2026-02-16 17:20:14 +01:00
parent 51329c4c65
commit c09c77b8a6
@@ -1,8 +1,9 @@
import { describe, expect, test, mock, beforeEach } from "bun:test"
import type { GitContext } from "../types"
// Mock dependencies before importing the module under test
let mockGitContext = {
let mockGitContext: GitContext = {
branch: "main",
recentCommits: ["abc1234 initial commit"],
files: [