Skip to content

Commit

Permalink
try increase timeout
Browse files Browse the repository at this point in the history
  • Loading branch information
artyom-jaksov-tl committed Nov 25, 2024
1 parent 4b501e1 commit d399529
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions tests/e2e/pages/hosted-payments-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 HostedPaymentsPage {
page: Page;
Expand All @@ -8,14 +8,14 @@ export class HostedPaymentsPage {
}

// Locators
mockBank = () => this.page.getByLabel('Select Mock UK Payments - Redirect Flow', { exact: true });
continueButton = () => this.page.getByTestId('confirm-redirect-button');
continueOnDesktopButton = () => this.page.getByTestId('continue-desktop');
mockBank = () => this.page.getByLabel('Mock UK Payments - Redirect Flow', { exact: true });
continueButton = () => this.page.getByText('Go to bank');
continueOnDesktopButton = () => this.page.getByText('on this device');

// Methods
async selectMockBankAndContinueOnDesktop() {
await this.selectMockBankAndContinue();
await this.continueOnDesktopButton().isVisible()
await expect(this.continueOnDesktopButton()).toBeVisible({timeout: 10000})
await this.continueOnDesktopButton().click();
}

Expand All @@ -24,9 +24,9 @@ export class HostedPaymentsPage {
}

private async selectMockBankAndContinue(){
await this.mockBank().isVisible();
await expect(this.mockBank()).toBeVisible({timeout: 10000})
await this.mockBank().click();
await this.continueButton().isVisible();
await expect(this.continueButton()).toBeVisible({timeout: 10000})
await this.continueButton().click();
}
}

0 comments on commit d399529

Please sign in to comment.