From d04f6c9ebcb21fe1d9045b7f735ca6bc1cb23a3c Mon Sep 17 00:00:00 2001 From: Alex Gleason Date: Tue, 9 Jun 2020 22:26:26 -0500 Subject: [PATCH] Test: LoginPage snapshots --- .../__snapshots__/login_page-test.js.snap | 62 +++++++++++++++++++ .../components/__tests__/login_page-test.js | 18 ++++++ 2 files changed, 80 insertions(+) create mode 100644 app/soapbox/features/auth_login/components/__tests__/__snapshots__/login_page-test.js.snap create mode 100644 app/soapbox/features/auth_login/components/__tests__/login_page-test.js diff --git a/app/soapbox/features/auth_login/components/__tests__/__snapshots__/login_page-test.js.snap b/app/soapbox/features/auth_login/components/__tests__/__snapshots__/login_page-test.js.snap new file mode 100644 index 000000000..35adf1d29 --- /dev/null +++ b/app/soapbox/features/auth_login/components/__tests__/__snapshots__/login_page-test.js.snap @@ -0,0 +1,62 @@ +// Jest Snapshot v1, https://goo.gl/fbAQLP + +exports[` renders correctly 1`] = ` +
+
+
+
+ +
+
+ +
+

+ + Trouble logging in? + +

+
+
+
+ +
+
+`; + +exports[` renders correctly 2`] = `null`; diff --git a/app/soapbox/features/auth_login/components/__tests__/login_page-test.js b/app/soapbox/features/auth_login/components/__tests__/login_page-test.js new file mode 100644 index 000000000..f0e3d7901 --- /dev/null +++ b/app/soapbox/features/auth_login/components/__tests__/login_page-test.js @@ -0,0 +1,18 @@ +import React from 'react'; +import LoginPage from '../login_page'; +import { createComponent, mockStore } from 'soapbox/test_helpers'; +import { Map as ImmutableMap } from 'immutable'; + +describe('', () => { + it('renders correctly', () => { + expect(createComponent( + + ).toJSON()).toMatchSnapshot(); + + const store = mockStore(ImmutableMap({ me: '1234' })); + expect(createComponent( + , + { store }, + ).toJSON()).toMatchSnapshot(); + }); +});