mirror of
https://github.com/element-hq/element-web
synced 2024-11-29 12:58:53 +03:00
test server switch in cypress login test (#11130)
This commit is contained in:
parent
e1cad41bc3
commit
9704c9fc13
1 changed files with 24 additions and 0 deletions
|
@ -47,6 +47,30 @@ describe("Login", () => {
|
||||||
// wait for the dialog to go away
|
// wait for the dialog to go away
|
||||||
cy.get(".mx_ServerPickerDialog").should("not.exist");
|
cy.get(".mx_ServerPickerDialog").should("not.exist");
|
||||||
|
|
||||||
|
cy.get(".mx_Spinner").should("not.exist");
|
||||||
|
cy.get(".mx_ServerPicker_server").should("have.text", homeserver.baseUrl);
|
||||||
|
|
||||||
|
cy.findByRole("button", { name: "Edit" }).click();
|
||||||
|
|
||||||
|
// select the default server again
|
||||||
|
cy.get(".mx_StyledRadioButton").first().click();
|
||||||
|
cy.findByRole("button", { name: "Continue" }).click();
|
||||||
|
cy.get(".mx_ServerPickerDialog").should("not.exist");
|
||||||
|
cy.get(".mx_Spinner").should("not.exist");
|
||||||
|
// name of default server
|
||||||
|
cy.get(".mx_ServerPicker_server").should("have.text", "server.invalid");
|
||||||
|
|
||||||
|
// switch back to the custom homeserver
|
||||||
|
|
||||||
|
cy.findByRole("button", { name: "Edit" }).click();
|
||||||
|
cy.findByRole("textbox", { name: "Other homeserver" }).type(homeserver.baseUrl);
|
||||||
|
cy.findByRole("button", { name: "Continue" }).click();
|
||||||
|
// wait for the dialog to go away
|
||||||
|
cy.get(".mx_ServerPickerDialog").should("not.exist");
|
||||||
|
|
||||||
|
cy.get(".mx_Spinner").should("not.exist");
|
||||||
|
cy.get(".mx_ServerPicker_server").should("have.text", homeserver.baseUrl);
|
||||||
|
|
||||||
cy.findByRole("textbox", { name: "Username", timeout: 15000 }).should("be.visible");
|
cy.findByRole("textbox", { name: "Username", timeout: 15000 }).should("be.visible");
|
||||||
// Disabled because flaky - see https://github.com/vector-im/element-web/issues/24688
|
// Disabled because flaky - see https://github.com/vector-im/element-web/issues/24688
|
||||||
//cy.percySnapshot("Login");
|
//cy.percySnapshot("Login");
|
||||||
|
|
Loading…
Reference in a new issue