Skip to content
This repository was archived by the owner on Oct 22, 2024. It is now read-only.

Commit fe402e2

Browse files
authored
Fix flaky mobile registration tests (#102)
* Fix flaky mobile registration tests Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> * Discard changes to src/theme.ts * Add comment Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> --------- Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
1 parent 0b3b499 commit fe402e2

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

test/components/structures/MatrixChat-test.tsx

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,10 @@ jest.mock("matrix-js-sdk/src/oidc/authorize", () => ({
6161
completeAuthorizationCodeGrant: jest.fn(),
6262
}));
6363

64+
// Stub out ThemeWatcher as the necessary bits for themes are done in element-web's index.html and thus are lacking here,
65+
// plus JSDOM's implementation of CSSStyleDeclaration has a bunch of differences to real browsers which cause issues.
66+
jest.mock("../../../src/settings/watchers/ThemeWatcher");
67+
6468
/** The matrix versions our mock server claims to support */
6569
const SERVER_SUPPORTED_MATRIX_VERSIONS = ["v1.1", "v1.5", "v1.6", "v1.8", "v1.9"];
6670

0 commit comments

Comments
 (0)