public async createRuleErrorCountThreshold()

in src/pom/serverless/pages/alerts.page.ts [33:47]


    public async createRuleErrorCountThreshold(ruleName: string, errorsNumber: string, timeNumber: string, timeUnit: string) {
        await this.manageRulesButton().click();
        await this.createRuleButton().click();
        await this.ruleNameInput().fill(ruleName);
        await this.errorCountThresholdType().click();
        await this.isAboveErrorsOption().click();
        await this.isAboveErrorsInput().fill(errorsNumber);
        await this.forTheLastOption().click();
        await this.timeNumberInput().fill(timeNumber);
        await this.timeUnitSelect().click();
        await this.timeUnitSelect().selectOption({ value: timeUnit });
        await this.saveRuleButton().click();
        await this.confirmButton().click();
        await expect(this.page.locator(`xpath=//button[@title='${ruleName}']`)).toBeVisible();
        }