From 064e3c297d17368002aadcbaf71be9d2f3a3385b Mon Sep 17 00:00:00 2001 From: Volodymyr Kolesnykov Date: Fri, 27 Sep 2024 04:50:45 +0300 Subject: [PATCH] test: add back delays for login to work around Playwright bugs --- tests/e2e/lib/loginpage.ts | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/tests/e2e/lib/loginpage.ts b/tests/e2e/lib/loginpage.ts index ac451649..cc1edb60 100644 --- a/tests/e2e/lib/loginpage.ts +++ b/tests/e2e/lib/loginpage.ts @@ -37,8 +37,18 @@ export class LoginPage { } public async login(username: string, password: string): Promise { + await this.userFieldLocator.click(); + // eslint-disable-next-line playwright/no-wait-for-timeout + await this.page.waitForTimeout(60); await this.userFieldLocator.fill(username); + + await this.passwordFieldLocator.click(); + // eslint-disable-next-line playwright/no-wait-for-timeout + await this.page.waitForTimeout(60); await this.passwordFieldLocator.fill(password); + + // eslint-disable-next-line playwright/no-wait-for-timeout + await this.page.waitForTimeout(60); await this.submitButtonLocator.click(); await this.page.waitForLoadState('domcontentloaded'); }