Fix flaky playwright tests (#28959) #4030
Annotations
4 errors, 5 warnings, and 1 notice
Run Playwright tests:
playwright/e2e/oidc/index.ts#L34
1) [Chrome] › crypto/backups-mas.spec.ts:31:9 › Encryption state after registration › user is prompted to set up recovery
Error: expect(received).toHaveLength(expected)
Expected length: 1
Received length: 0
Received array: []
Call Log:
- Test timeout of 30000ms exceeded
at oidc/index.ts:34
32 | messages = await mailhog.messages();
33 | expect(messages.items).toHaveLength(1);
> 34 | }).toPass();
| ^
35 | expect(messages.items[0].to).toEqual(`${username} <${email}>`);
36 | const [, code] = messages.items[0].text.match(/Your verification code to confirm this email address is: (\d{6})/);
37 |
at registerAccountMas (/home/runner/work/element-web/element-web/playwright/e2e/oidc/index.ts:34:8)
at /home/runner/work/element-web/element-web/playwright/e2e/crypto/backups-mas.spec.ts:34:9
|
Run Playwright tests:
playwright/e2e/oidc/index.ts#L34
2) [Chrome] › crypto/backups-mas.spec.ts:48:9 › Key backup reset from elsewhere › Key backup is disabled when reset from elsewhere
Error: expect(received).toHaveLength(expected)
Expected length: 1
Received length: 0
Received array: []
Call Log:
- Test timeout of 30000ms exceeded
at oidc/index.ts:34
32 | messages = await mailhog.messages();
33 | expect(messages.items).toHaveLength(1);
> 34 | }).toPass();
| ^
35 | expect(messages.items[0].to).toEqual(`${username} <${email}>`);
36 | const [, code] = messages.items[0].text.match(/Your verification code to confirm this email address is: (\d{6})/);
37 |
at registerAccountMas (/home/runner/work/element-web/element-web/playwright/e2e/oidc/index.ts:34:8)
at /home/runner/work/element-web/element-web/playwright/e2e/crypto/backups-mas.spec.ts:58:9
|
Run Playwright tests:
playwright/e2e/login/utils.ts#L37
3) [Chrome] › login/soft_logout_oauth.spec.ts:40:9 › Soft logout with SSO user › shows the soft-logout page when a request fails, and allows a re-login
Error: Timed out 5000ms waiting for expect(locator).toBeVisible()
Locator: getByRole('heading', { name: 'Create your account' })
Expected: visible
Received: <element(s) not found>
Call log:
- expect.toBeVisible with timeout 5000ms
- waiting for getByRole('heading', { name: 'Create your account' })
at login/utils.ts:37
35 |
36 | // Synapse prompts us to pick a user ID
> 37 | await expect(page.getByRole("heading", { name: "Create your account" })).toBeVisible();
| ^
38 | await page.getByRole("textbox", { name: "Username (required)" }).fill("alice");
39 |
40 | // wait for username validation to start, and complete
at doTokenRegistration (/home/runner/work/element-web/element-web/playwright/e2e/login/utils.ts:37:78)
at Object.user (/home/runner/work/element-web/element-web/playwright/e2e/login/soft_logout_oauth.spec.ts:30:26)
|
Run Playwright tests:
playwright/e2e/register/email.spec.ts#L55
4) [Chrome] › register/email.spec.ts:34:9 › Email Registration › registers an account and lands on the use case selection screen @screenshot
Error: expect(received).toHaveLength(expected)
Expected length: 1
Received length: 2
Received array: [{"Content": [Object], "Created": "2025-01-13T09:51:58.635761197Z", "From": [Object], "ID": "[email protected]", "MIME": [Object], "Raw": [Object], "To": [Array]}, {"Content": [Object], "Created": "2025-01-13T09:51:54.26067055Z", "From": [Object], "ID": "[email protected]", "MIME": [Object], "Raw": [Object], "To": [Array]}]
53 |
54 | const messages = await mailhogClient.messages();
> 55 | expect(messages.items).toHaveLength(1);
| ^
56 | expect(messages.items[0].to).toEqual("[email protected]");
57 | const [emailLink] = messages.items[0].text.match(/http.+/);
58 | await request.get(emailLink); // "Click" the link in the email
at /home/runner/work/element-web/element-web/playwright/e2e/register/email.spec.ts:55:36
|
Run Playwright tests:
[Chrome] › timeline/timeline.spec.ts#L1
[Chrome] › timeline/timeline.spec.ts took 1.3m
|
Run Playwright tests:
[Chrome] › login/login-consent.spec.ts#L1
[Chrome] › login/login-consent.spec.ts took 43.6s
|
Run Playwright tests:
[Chrome] › user-onboarding/user-onboarding-new.spec.ts#L1
[Chrome] › user-onboarding/user-onboarding-new.spec.ts took 23.7s
|
Run Playwright tests:
[Chrome] › threads/threads.spec.ts#L1
[Chrome] › threads/threads.spec.ts took 23.0s
|
Run Playwright tests:
[Chrome] › app-loading/guest-registration.spec.ts#L1
[Chrome] › app-loading/guest-registration.spec.ts took 18.5s
|
Run Playwright tests
4 flaky
[Chrome] › crypto/backups-mas.spec.ts:31:9 › Encryption state after registration › user is prompted to set up recovery
[Chrome] › crypto/backups-mas.spec.ts:48:9 › Key backup reset from elsewhere › Key backup is disabled when reset from elsewhere
[Chrome] › login/soft_logout_oauth.spec.ts:40:9 › Soft logout with SSO user › shows the soft-logout page when a request fails, and allows a re-login
[Chrome] › register/email.spec.ts:34:9 › Email Registration › registers an account and lands on the use case selection screen @screenshot
2 skipped
65 passed (8.3m)
|
Loading