Skip to content

Commit

Permalink
add timeouts
Browse files Browse the repository at this point in the history
  • Loading branch information
artyom-jaksov-tl committed Oct 22, 2024
1 parent 571240b commit 049df7a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
6 changes: 4 additions & 2 deletions tests/e2e/pages/mock-uk-bank-accounts-page.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Page } from '@playwright/test';
import { expect, Page } from '@playwright/test';

export class MockUkBankAccountsPage {
page: Page;
Expand All @@ -8,11 +8,13 @@ export class MockUkBankAccountsPage {
}

// Locators
currentAccount = () => this.page.getByText('Select account');
continueButton = () => this.page.getByRole('button', { name: 'Continue' });

// Methods
async selectAccountAndContinue() {
await this.continueButton().isVisible({timeout:10000});
await expect(this.currentAccount()).toBeVisible({ timeout: 10000 })
await this.continueButton().isVisible();
await this.continueButton().click({force: true});
}
}
2 changes: 1 addition & 1 deletion tests/e2e/pages/payment-confirmation-page.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ export class PaymentConfirmationPage {

// Methods
async waitForProcessingAndContinue() {
await expect(this.paymentProcessingText().or(this.paymentConfirmedText())).toBeVisible({timeout: 15000})
await expect(this.paymentProcessingText().or(this.paymentConfirmedText())).toBeVisible({timeout: 20000})
await expect(this.continueButton()).toBeVisible();
await this.continueButton().click();
}
Expand Down

0 comments on commit 049df7a

Please sign in to comment.