From 74e2362f23a2d656d79973125d666d620525f366 Mon Sep 17 00:00:00 2001 From: Michael Telatynski <7t3chguy@gmail.com> Date: Mon, 18 Nov 2024 14:52:59 +0000 Subject: [PATCH] Iterate Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> --- .../views/elements/AppTile-test.tsx | 2 + .../__snapshots__/AppTile-test.tsx.snap | 70 +++++ .../vector/__snapshots__/init-test.ts.snap | 255 +++++++++++++++++- test/unit-tests/vector/init-test.ts | 4 +- 4 files changed, 328 insertions(+), 3 deletions(-) diff --git a/test/unit-tests/components/views/elements/AppTile-test.tsx b/test/unit-tests/components/views/elements/AppTile-test.tsx index 27ce1ca0553..12363f56f04 100644 --- a/test/unit-tests/components/views/elements/AppTile-test.tsx +++ b/test/unit-tests/components/views/elements/AppTile-test.tsx @@ -159,6 +159,8 @@ describe("AppTile", () => { await expect(renderResult.findByText("Example 1")).resolves.toBeInTheDocument(); expect(ActiveWidgetStore.instance.isLive("1", "r1")).toBe(true); + const { asFragment } = renderResult; + expect(asFragment()).toMatchSnapshot(); // We want to verify that as we change to room 2, we should close the // right panel and destroy the widget. diff --git a/test/unit-tests/components/views/elements/__snapshots__/AppTile-test.tsx.snap b/test/unit-tests/components/views/elements/__snapshots__/AppTile-test.tsx.snap index 21cd18f6e97..f039d945143 100644 --- a/test/unit-tests/components/views/elements/__snapshots__/AppTile-test.tsx.snap +++ b/test/unit-tests/components/views/elements/__snapshots__/AppTile-test.tsx.snap @@ -1,5 +1,75 @@ // Jest Snapshot v1, https://goo.gl/fbAQLP +exports[`AppTile destroys non-persisted right panel widget on room change 1`] = ` + + + +`; + exports[`AppTile for a persistent app should render 1`] = `
+> +
+ +
+

+ Error title +

+

+ msg1 +

+

+ msg2 +

+
+
+
`; exports[`showIncompatibleBrowser should match snapshot 1`] = `
+> +
+ +
+

+ Element does not support this browser +

+

+ Element uses some browser features which are not available in your current browser. If you continue, some features may stop working and there is a risk that you may lose data in the future. +

+

+ + For the best experience, use + + Chrome + + , + + Firefox + + , + + Edge + + , or + + Safari + + . + +

+
+ + +
+
+