keycloak-scim/cypress/support/pages/admin_console/manage/clients/CreateInitialAccessTokenPage.ts
2022-04-19 08:25:57 -04:00

18 lines
554 B
TypeScript

import CommonPage from "../../../CommonPage";
export default class CreateInitialAccessTokenPage extends CommonPage {
private expirationInput = "expiration";
private countInput = "count";
private countPlusBtn = '[data-testid="count"] [aria-label="Plus"]';
fillNewTokenData(expiration: number, count: number) {
cy.findByTestId(this.expirationInput).clear().type(expiration.toString());
cy.findByTestId(this.countInput).clear();
for (let i = 0; i < count; i++) {
cy.get(this.countPlusBtn).click();
}
return this;
}
}