test(23-00): Wave 0 test stubs for Phase 23 components and hooks

- ChatSpecCard.test.tsx — 9 it.todo() entries covering spec card behaviors
- ChatHandoffIndicator.test.tsx — 3 it.todo() entries
- ChatTaskCreatedBadge.test.tsx — 4 it.todo() entries
- ChatStatusUpdateBadge.test.tsx — 3 it.todo() entries
- useBrainstormerDefault.test.ts — 4 it.todo() entries
- All 23 todo tests found and skipped by vitest (0 failures)
This commit is contained in:
Nexus Dev 2026-04-01 21:41:58 +00:00
parent fe51918ed2
commit 2542442e33
5 changed files with 48 additions and 0 deletions

View file

@ -0,0 +1,8 @@
// @vitest-environment jsdom
import { describe, it } from "vitest";
describe("ChatHandoffIndicator", () => {
it.todo("renders content text between two hr elements");
it.todo("has aria-label for agent handoff");
it.todo("hr elements have aria-hidden=true");
});

View file

@ -0,0 +1,14 @@
// @vitest-environment jsdom
import { describe, it } from "vitest";
describe("ChatSpecCard", () => {
it.todo("renders four spec sections: What, Why, Constraints, Success");
it.todo("parses JSON content and displays field values");
it.todo("shows error fallback on JSON parse failure");
it.todo("Send to PM button calls onHandoff with spec content");
it.todo("Edit button switches to textarea edit mode");
it.todo("Save changes button disabled when all fields empty");
it.todo("Discard button reverts to read-only mode");
it.todo("Save as Draft button adds [Draft] badge");
it.todo("renders with role=region and aria-label=Specification");
});

View file

@ -0,0 +1,8 @@
// @vitest-environment jsdom
import { describe, it } from "vitest";
describe("ChatStatusUpdateBadge", () => {
it.todo("renders CheckCircle2 icon, agent name, and task reference");
it.todo("View task link navigates to issue detail");
it.todo("has role=status on container");
});

View file

@ -0,0 +1,9 @@
// @vitest-environment jsdom
import { describe, it } from "vitest";
describe("ChatTaskCreatedBadge", () => {
it.todo("shows Creating task... when taskId is not provided");
it.todo("renders taskId, taskTitle, and View task link when resolved");
it.todo("View task link has correct aria-label");
it.todo("has role=status on container");
});

View file

@ -0,0 +1,9 @@
// @vitest-environment jsdom
import { describe, it } from "vitest";
describe("useBrainstormerDefault", () => {
it.todo("returns general role agent ID when available");
it.todo("returns first by createdAt when multiple general agents exist");
it.todo("returns null when no agents loaded");
it.todo("returns null when no general agent exists");
});