diff --git a/alfa-client/apps/admin-e2e/src/page-objects/login.po.ts b/alfa-client/apps/admin-e2e/src/page-objects/login.po.ts index e44d469b42df25d800256e4dfb013b9bab52af3d..73005caaf69cb0be2990541fdabe003326a20153 100644 --- a/alfa-client/apps/admin-e2e/src/page-objects/login.po.ts +++ b/alfa-client/apps/admin-e2e/src/page-objects/login.po.ts @@ -2,11 +2,11 @@ export class LoginPage { private readonly locatorLogin: string = '#kc-login'; private readonly locatorBarrierefreiheitLink: string = '#kc-barrierefreiheit'; - public getLogin() { + public getLogin(): Cypress.Chainable<JQuery<HTMLElement>> { return cy.get(this.locatorLogin); } - public getBarrierefreiheitLink() { + public getBarrierefreiheitLink(): Cypress.Chainable<JQuery<HTMLElement>> { return cy.get(this.locatorBarrierefreiheitLink); } } diff --git a/alfa-client/apps/admin-e2e/src/support/cypress.util.ts b/alfa-client/apps/admin-e2e/src/support/cypress.util.ts index cf78eeaa8b016603acbd8ebde5c4630fd18b3f2e..60db5d0f8610ec03e2cd6c0c34a71e45555612ca 100644 --- a/alfa-client/apps/admin-e2e/src/support/cypress.util.ts +++ b/alfa-client/apps/admin-e2e/src/support/cypress.util.ts @@ -33,11 +33,11 @@ export function notContainClass(element: Cypress.Chainable<Element>, cssClass: s element.should('not.have.class', cssClass); } -export function exist(element: Cypress.Chainable<Element>): void { +export function exist(element: Cypress.Chainable<Element> | Cypress.Chainable<JQuery<HTMLElement>>): void { element.should('exist'); } -export function notExist(element: Cypress.Chainable<Element>): void { +export function notExist(element: Cypress.Chainable<Element> | Cypress.Chainable<JQuery<HTMLElement>>): void { element.should('not.exist'); } diff --git a/alfa-client/apps/alfa-e2e/src/page-objects/login.po.ts b/alfa-client/apps/alfa-e2e/src/page-objects/login.po.ts index e44d469b42df25d800256e4dfb013b9bab52af3d..73005caaf69cb0be2990541fdabe003326a20153 100644 --- a/alfa-client/apps/alfa-e2e/src/page-objects/login.po.ts +++ b/alfa-client/apps/alfa-e2e/src/page-objects/login.po.ts @@ -2,11 +2,11 @@ export class LoginPage { private readonly locatorLogin: string = '#kc-login'; private readonly locatorBarrierefreiheitLink: string = '#kc-barrierefreiheit'; - public getLogin() { + public getLogin(): Cypress.Chainable<JQuery<HTMLElement>> { return cy.get(this.locatorLogin); } - public getBarrierefreiheitLink() { + public getBarrierefreiheitLink(): Cypress.Chainable<JQuery<HTMLElement>> { return cy.get(this.locatorBarrierefreiheitLink); } }