import { afterEach, describe, expect, it, vi } from "vitest"; import { cleanup, render, screen } from "@testing-library/react"; import type { Workflow, WorkflowStep } from "@/lib/types/http"; import { StepDeleteDialog, WorkflowDeleteDialog } from "./workflow-card-dialogs"; /** * These dialogs used to build their descriptions by concatenation — an English * `s` for the plural and a leading-space suffix for the unsaved-changes hint. * Both are now catalog messages (`count` + `_one`/`_other`, and a joined * sentence), so the shapes that would silently regress are pinned here: * * - the singular / plural task counts in each of the three step variants, * - the space between the base sentence and the unsaved-changes hint, * - the step name arriving as an interpolated value rather than baked into * the message (steps are renamed freely, so it is user data). */ const STEP_NAME = "In Review"; const NO_WORKFLOWS: Workflow[] = []; const NO_STEPS: WorkflowStep[] = []; // Only `id` and `name` are read (the migration