feat(workflow-bar): optimistic F1 at start; all-green when session finalized

This commit is contained in:
2026-07-03 13:22:09 +02:00
parent 37b3eb45e9
commit e630ac98f9
5 changed files with 33 additions and 10 deletions
+3
View File
@@ -38,6 +38,9 @@ test("F1: create session -> widget via SSE -> respond -> POST /response", async
// Wait for the session to be created and SSE to connect
await waitFor(() => expect(FakeEventSource.instances).toHaveLength(1));
// Optimistic lifecycle: a brand-new question paints F1 immediately (before any gate).
await waitFor(() => expect(useSessionStore.getState().currentPhase).toBe("F1"));
// Simulate the backend emitting the F1 widget via a NAMED SSE event
// (`event: ui_request`) — the same addEventListener path production uses.
act(() =>