Attempt to set the language when setting up Cypress tests (#8964)

pull/28217/head
Andy Balaam 2022-07-05 11:14:24 +01:00 committed by GitHub
parent 4b624fd58b
commit 08c607718d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 0 deletions

View File

@ -82,6 +82,9 @@ Cypress.Commands.add("initTestUser", (synapse: SynapseInstance, displayName: str
win.localStorage.setItem("mx_is_guest", "false");
win.localStorage.setItem("mx_has_pickle_key", "false");
win.localStorage.setItem("mx_has_access_token", "true");
// Ensure the language is set to a consistent value
win.localStorage.setItem("mx_local_settings", '{"language":"en"}');
});
return cy.visit("/").then(() => {