fix language dependency of some selectors in login and user profile tests

This commit is contained in:
mahula 2022-09-28 10:38:46 +02:00
parent bb7e8d2b3d
commit 480378a182
3 changed files with 7 additions and 6 deletions

View File

@ -2,8 +2,8 @@
export class LoginPage {
// selectors
emailInput = "#Email-input-field";
passwordInput = "#Password-input-field";
emailInput = "input[type=email]";
passwordInput = "input[type=password]";
submitBtn = "[type=submit]";
emailHint = "#vee_Email";
passwordHint = "#vee_Password";

View File

@ -4,8 +4,8 @@ export class ProfilePage {
// selectors
openChangePassword = "[data-test=open-password-change-form]";
oldPasswordInput = "#password-input-field";
newPasswordInput = "#New-password-input-field";
newPasswordRepeatInput = "#Repeat-new-password-input-field";
newPasswordInput = "#new-password-input-field";
newPasswordRepeatInput = "#repeat-new-password-input-field";
submitNewPasswordBtn = "[data-test=submit-new-password-btn]";
goto() {
@ -19,12 +19,12 @@ export class ProfilePage {
}
enterNewPassword(password: string) {
cy.get(this.newPasswordInput).clear().type(password);
cy.get(this.newPasswordInput).find("input").clear().type(password);
return this;
}
enterRepeatPassword(password: string) {
cy.get(this.newPasswordRepeatInput).clear().type(password);
cy.get(this.newPasswordRepeatInput).find("input").clear().type(password);
return this;
}

View File

@ -29,6 +29,7 @@
required: true,
samePassword: value.password,
}"
id="repeat-new-password-input-field"
:label="register ? $t('form.passwordRepeat') : $t('form.password_new_repeat')"
:immediate="true"
:name="createId(register ? $t('form.passwordRepeat') : $t('form.password_new_repeat'))"