Clean up some unit test logs (#7857)

* kill some unit test logs in arrays-test

Signed-off-by: Kerry Archibald <kerrya@element.io>

* remove mock logs that are asserted against anyway

* remove more logs

Signed-off-by: Kerry Archibald <kerrya@element.io>

* fix safeCOunterpartTranslate warnings in tests

Signed-off-by: Kerry Archibald <kerrya@element.io>

* more safeCounterpartTranslate warnings

Signed-off-by: Kerry Archibald <kerrya@element.io>

* lint

Signed-off-by: Kerry Archibald <kerrya@element.io>

* remove more logs

Signed-off-by: Kerry Archibald <kerrya@element.io>

* add helper

Signed-off-by: Kerry Archibald <kerrya@element.io>

* naming

Signed-off-by: Kerry Archibald <kerrya@element.io>
This commit is contained in:
Kerry
2022-02-21 17:57:44 +01:00
committed by GitHub
parent e2827b4082
commit 8b9263c808
13 changed files with 108 additions and 91 deletions

View File

@@ -139,7 +139,7 @@ describe("AppTile", () => {
const instance = renderer.root.findByType(AppTile).instance;
const endWidgetActions = jest.spyOn(instance, "endWidgetActions");
console.log("Switch to room 2");
// Switch to room 2
dis.dispatch({
action: Action.ViewRoom,
room_id: "r2",
@@ -194,7 +194,7 @@ describe("AppTile", () => {
const instance = renderer.root.findByType(AppTile).instance;
const endWidgetActions = jest.spyOn(instance, "endWidgetActions");
console.log("Move widget to center");
// Move widget to center
// Stop mocking settings so that the widget move can take effect
mockSettings.mockRestore();

View File

@@ -352,6 +352,7 @@ describe("<TextualBody />", () => {
},
event: true,
});
jest.spyOn(ev, 'replacingEventDate').mockReturnValue(new Date(1993, 7, 3));
ev.makeReplaced(ev2);
wrapper.setProps({

View File

@@ -106,7 +106,7 @@ exports[`<RoomPreviewBar /> with an invite with an invited email when client has
This invite to RoomPreviewBar-test-room was sent to test@test.com
</h3>
<p>
Share this email in Settings to receive invites directly in .
Share this email in Settings to receive invites directly in Element.
</p>
</div>
`;
@@ -119,7 +119,7 @@ exports[`<RoomPreviewBar /> with an invite with an invited email when client has
This invite to RoomPreviewBar-test-room was sent to test@test.com
</h3>
<p>
Share this email in Settings to receive invites directly in .
Share this email in Settings to receive invites directly in Element.
</p>
</div>
`;
@@ -132,7 +132,7 @@ exports[`<RoomPreviewBar /> with an invite with an invited email when client has
This invite to RoomPreviewBar-test-room was sent to test@test.com
</h3>
<p>
Use an identity server in Settings to receive invites directly in .
Use an identity server in Settings to receive invites directly in Element.
</p>
</div>
`;
@@ -145,7 +145,7 @@ exports[`<RoomPreviewBar /> with an invite with an invited email when invitedEma
This invite to RoomPreviewBar-test-room was sent to test@test.com which is not associated with your account
</h3>
<p>
Link this email with your account in Settings to receive invites directly in .
Link this email with your account in Settings to receive invites directly in Element.
</p>
</div>
`;