From a5522faa42d1f3fd1faf3d4ca13326bcc3c5ef3a Mon Sep 17 00:00:00 2001 From: diana-villalvazo-wgu Date: Mon, 12 May 2025 17:15:40 -0600 Subject: [PATCH] test: update related tests --- .../__snapshots__/index.test.jsx.snap | 6 ++- .../Dashboard/DashboardLayout.test.jsx | 5 +-- .../DashboardLayout.test.jsx.snap | 38 ++++++++++++------- .../__snapshots__/index.test.jsx.snap | 6 +-- 4 files changed, 33 insertions(+), 22 deletions(-) diff --git a/src/containers/CoursesPanel/NoCoursesView/__snapshots__/index.test.jsx.snap b/src/containers/CoursesPanel/NoCoursesView/__snapshots__/index.test.jsx.snap index 8f6fabd..fc408e1 100644 --- a/src/containers/CoursesPanel/NoCoursesView/__snapshots__/index.test.jsx.snap +++ b/src/containers/CoursesPanel/NoCoursesView/__snapshots__/index.test.jsx.snap @@ -9,9 +9,11 @@ exports[`NoCoursesView snapshot 1`] = ` alt="No Courses view banner" src="icon/mock/path" /> -

+

Looking for a new challenge? -

+

Explore our courses to add them to your dashboard.

diff --git a/src/containers/Dashboard/DashboardLayout.test.jsx b/src/containers/Dashboard/DashboardLayout.test.jsx index 4e92637..fabb984 100644 --- a/src/containers/Dashboard/DashboardLayout.test.jsx +++ b/src/containers/Dashboard/DashboardLayout.test.jsx @@ -84,10 +84,9 @@ describe('DashboardLayout', () => { describe('not collapsed', () => { const testWidgetSpacing = () => { - it('shows a blank (nbsp) h2 spacer component above widget sidebar', () => { + it('shows not-collapsed class on widget sidebar', () => { const columns = el.instance.findByType(Col); - // nonbreaking space equivalent - expect(columns[1].findByType('h2')[0].children[0].el).toEqual('\xA0'); + expect(columns[1].props.className).toContain('not-collapsed'); }); }; describe('sidebar showing', () => { diff --git a/src/containers/Dashboard/__snapshots__/DashboardLayout.test.jsx.snap b/src/containers/Dashboard/__snapshots__/DashboardLayout.test.jsx.snap index dc7e7a3..c1cd867 100644 --- a/src/containers/Dashboard/__snapshots__/DashboardLayout.test.jsx.snap +++ b/src/containers/Dashboard/__snapshots__/DashboardLayout.test.jsx.snap @@ -24,7 +24,12 @@ exports[`DashboardLayout collapsed sidebar not showing snapshot 1`] = ` test-children -

-   -

@@ -161,7 +171,12 @@ exports[`DashboardLayout not collapsed sidebar showing snapshot 1`] = ` test-children -

-   -

diff --git a/src/containers/LearnerDashboardHeader/ConfirmEmailBanner/__snapshots__/index.test.jsx.snap b/src/containers/LearnerDashboardHeader/ConfirmEmailBanner/__snapshots__/index.test.jsx.snap index b68c507..315dbee 100644 --- a/src/containers/LearnerDashboardHeader/ConfirmEmailBanner/__snapshots__/index.test.jsx.snap +++ b/src/containers/LearnerDashboardHeader/ConfirmEmailBanner/__snapshots__/index.test.jsx.snap @@ -55,11 +55,11 @@ exports[`ConfirmEmailBanner snapshot Show on unverified 1`] = ` onClose={[MockFunction closeConfirmModal]} title="" > -

Confirm your email -

+