diff options
Diffstat (limited to 'frontend/app/components/BorderedContainerWithCaption.test.tsx')
| -rw-r--r-- | frontend/app/components/BorderedContainerWithCaption.test.tsx | 54 |
1 files changed, 27 insertions, 27 deletions
diff --git a/frontend/app/components/BorderedContainerWithCaption.test.tsx b/frontend/app/components/BorderedContainerWithCaption.test.tsx index 621dcb3..da6246b 100644 --- a/frontend/app/components/BorderedContainerWithCaption.test.tsx +++ b/frontend/app/components/BorderedContainerWithCaption.test.tsx @@ -6,36 +6,36 @@ import { afterEach, describe, expect, test } from "vitest"; import BorderedContainerWithCaption from "./BorderedContainerWithCaption"; afterEach(() => { - cleanup(); + cleanup(); }); describe("BorderedContainerWithCaption", () => { - test("renders caption as heading", () => { - render( - <BorderedContainerWithCaption caption="Test Caption"> - Content - </BorderedContainerWithCaption>, - ); - expect(screen.getByText("Test Caption")).toBeDefined(); - expect(screen.getByText("Test Caption").tagName).toBe("H2"); - }); + test("renders caption as heading", () => { + render( + <BorderedContainerWithCaption caption="Test Caption"> + Content + </BorderedContainerWithCaption>, + ); + expect(screen.getByText("Test Caption")).toBeDefined(); + expect(screen.getByText("Test Caption").tagName).toBe("H2"); + }); - test("renders children", () => { - render( - <BorderedContainerWithCaption caption="Title"> - Child Content - </BorderedContainerWithCaption>, - ); - expect(screen.getByText("Child Content")).toBeDefined(); - }); + test("renders children", () => { + render( + <BorderedContainerWithCaption caption="Title"> + Child Content + </BorderedContainerWithCaption>, + ); + expect(screen.getByText("Child Content")).toBeDefined(); + }); - test("wraps in bordered container with blue border", () => { - render( - <BorderedContainerWithCaption caption="Title"> - Content - </BorderedContainerWithCaption>, - ); - const container = screen.getByText("Content").closest(".border-2"); - expect(container).not.toBeNull(); - }); + test("wraps in bordered container with blue border", () => { + render( + <BorderedContainerWithCaption caption="Title"> + Content + </BorderedContainerWithCaption>, + ); + const container = screen.getByText("Content").closest(".border-2"); + expect(container).not.toBeNull(); + }); }); |
