diff --git a/src/core/client/auth/test/navigation.spec.tsx b/src/core/client/auth/test/navigation.spec.tsx index 36ba888d8..3d71208cf 100644 --- a/src/core/client/auth/test/navigation.spec.tsx +++ b/src/core/client/auth/test/navigation.spec.tsx @@ -27,6 +27,7 @@ function createTestRenderer(initialView: string): ReactTestRenderer { sessionStorage: createInMemoryStorage(), rest: new RestClient("http://localhost/api"), postMessage: new PostMessageService(), + browserInfo: { ios: false }, }; return TestRenderer.create( diff --git a/src/core/client/auth/test/signIn.spec.tsx b/src/core/client/auth/test/signIn.spec.tsx index 848a05934..ca96d90f5 100644 --- a/src/core/client/auth/test/signIn.spec.tsx +++ b/src/core/client/auth/test/signIn.spec.tsx @@ -37,6 +37,7 @@ beforeEach(() => { sessionStorage: createInMemoryStorage(), rest: new RestClient("http://localhost/api"), postMessage: new PostMessageService(), + browserInfo: { ios: false }, }; testRenderer = TestRenderer.create( diff --git a/src/core/client/auth/test/signUp.spec.tsx b/src/core/client/auth/test/signUp.spec.tsx index a4b36e3d4..7a05e432e 100644 --- a/src/core/client/auth/test/signUp.spec.tsx +++ b/src/core/client/auth/test/signUp.spec.tsx @@ -37,6 +37,7 @@ beforeEach(() => { sessionStorage: createInMemoryStorage(), rest: new RestClient("http://localhost/api"), postMessage: new PostMessageService(), + browserInfo: { ios: false }, }; testRenderer = TestRenderer.create( diff --git a/src/core/client/stream/test/__snapshots__/postComment.spec.tsx.snap b/src/core/client/stream/test/__snapshots__/postComment.spec.tsx.snap index eb3613b12..c8a653b05 100644 --- a/src/core/client/stream/test/__snapshots__/postComment.spec.tsx.snap +++ b/src/core/client/stream/test/__snapshots__/postComment.spec.tsx.snap @@ -1,6 +1,6 @@ // Jest Snapshot v1, https://goo.gl/fbAQLP -exports[`post a comment 1`] = ` +exports[`post a comment: optimistic response 1`] = `
@@ -341,7 +341,7 @@ exports[`post a comment 1`] = `
`; -exports[`post a comment 2`] = ` +exports[`post a comment: server response 1`] = `
diff --git a/src/core/client/stream/test/__snapshots__/postReply.spec.tsx.snap b/src/core/client/stream/test/__snapshots__/postReply.spec.tsx.snap index 8e25deff4..8c81eba96 100644 --- a/src/core/client/stream/test/__snapshots__/postReply.spec.tsx.snap +++ b/src/core/client/stream/test/__snapshots__/postReply.spec.tsx.snap @@ -1,6 +1,6 @@ // Jest Snapshot v1, https://goo.gl/fbAQLP -exports[`post a reply 1`] = ` +exports[`post a reply: open reply form 1`] = `
@@ -420,7 +420,7 @@ exports[`post a reply 1`] = `
`; -exports[`post a reply 2`] = ` +exports[`post a reply: optimistic response 1`] = `
@@ -893,7 +893,7 @@ exports[`post a reply 2`] = `
`; -exports[`post a reply 3`] = ` +exports[`post a reply: server response 1`] = `
diff --git a/src/core/client/stream/test/postComment.spec.tsx b/src/core/client/stream/test/postComment.spec.tsx index 4aa831cdd..2e2f4c405 100644 --- a/src/core/client/stream/test/postComment.spec.tsx +++ b/src/core/client/stream/test/postComment.spec.tsx @@ -88,11 +88,11 @@ it("post a comment", async () => { timekeeper.reset(); // Test optimistic response. - expect(testRenderer.toJSON()).toMatchSnapshot(); + expect(testRenderer.toJSON()).toMatchSnapshot("optimistic response"); // Wait for loading. await timeout(); // Test after server response. - expect(testRenderer.toJSON()).toMatchSnapshot(); + expect(testRenderer.toJSON()).toMatchSnapshot("server response"); }); diff --git a/src/core/client/stream/test/postReply.spec.tsx b/src/core/client/stream/test/postReply.spec.tsx index 3aa117e44..b0270c52d 100644 --- a/src/core/client/stream/test/postReply.spec.tsx +++ b/src/core/client/stream/test/postReply.spec.tsx @@ -86,7 +86,7 @@ it("post a reply", async () => { .props.onClick(); await timeout(); - expect(testRenderer.toJSON()).toMatchSnapshot(); + expect(testRenderer.toJSON()).toMatchSnapshot("open reply form"); // Write reply . testRenderer.root @@ -98,12 +98,12 @@ it("post a reply", async () => { .findByProps({ id: "comments-replyCommentForm-form-comment-0" }) .props.onSubmit(); // Test optimistic response. - expect(testRenderer.toJSON()).toMatchSnapshot(); + expect(testRenderer.toJSON()).toMatchSnapshot("optimistic response"); timekeeper.reset(); // Wait for loading. await timeout(); // Test after server response. - expect(testRenderer.toJSON()).toMatchSnapshot(); + expect(testRenderer.toJSON()).toMatchSnapshot("server response"); });