mirror of
https://github.com/ToolJet/ToolJet
synced 2026-05-05 22:38:48 +00:00
* Added cypress test for profile settings page * Updated common selectors * Updated common text * Added functions for random names * Added data-cy attributes for components * Added verification for the input value * Added password field validation * Added common utils file * Added wait * Updated login error toast
16 lines
1 KiB
JavaScript
16 lines
1 KiB
JavaScript
import { profileSelector } from "Selectors/profile";
|
|
import { profileText } from "Texts/profile";
|
|
|
|
export const profilePageElements = () =>{
|
|
for(const elements in profileSelector.profileElements ){
|
|
cy.get(profileSelector.profileElements[elements]).should("be.visible").and("have.text",profileText.profileElements[elements]);
|
|
}
|
|
cy.get(profileSelector.updateButton).should("be.visible").and("have.text", profileText.updateButton);
|
|
cy.get(profileSelector.changePasswordButton).should("be.visible").and("have.text", profileText.changePasswordButton);
|
|
cy.get(profileSelector.firstNameInput).should("be.visible").and("have.value", profileText.firstName);
|
|
cy.get(profileSelector.lastNameInput).should("be.visible").and("have.value", profileText.lastName);
|
|
cy.get(profileSelector.emailInput).should("be.visible").and("have.value", profileText.email);
|
|
cy.get(profileSelector.currentPasswordField).should("be.visible").should("be.visible");
|
|
cy.get(profileSelector.newPasswordField).should("be.visible").should("be.visible");
|
|
};
|
|
|