Skip to content

fix: Flaky 2FA tests#10283

Merged
zomars merged 4 commits intomainfrom
fix/2fa-tests
Jul 20, 2023
Merged

fix: Flaky 2FA tests#10283
zomars merged 4 commits intomainfrom
fix/2fa-tests

Conversation

@joeauyeung
Copy link
Copy Markdown
Contributor

What does this PR do?

This PR fixes the "enable 2FA test" by waiting for the enable 2FA dialog box to disappear and wait to see if the enable 2FA switch is set to true

Fixes # (issue)

Requirement/Documentation

  • If there is a requirement document, please, share it here.
  • If there is ab UI/UX design document, please, share it here.

Type of change

  • Bug fix (non-breaking change which fixes an issue)

How should this be tested?

  • Run "Enable 2FA" test

Mandatory Tasks

  • Make sure you have self-reviewed the code. A decent size PR without self-review might be rejected.

Checklist

  • I haven't added tests that prove my fix is effective or that my feature works
  • I haven't checked if new and existing unit tests pass locally with my changes

@vercel
Copy link
Copy Markdown

vercel Bot commented Jul 20, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
api ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 20, 2023 7:37pm
cal-demo ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 20, 2023 7:37pm
dev ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 20, 2023 7:37pm
3 Ignored Deployments
Name Status Preview Comments Updated (UTC)
cal ⬜️ Ignored (Inspect) Jul 20, 2023 7:37pm
qa ⬜️ Ignored (Inspect) Jul 20, 2023 7:37pm
ui ⬜️ Ignored (Inspect) Visit Preview Jul 20, 2023 7:37pm

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Jul 20, 2023

Thank you for following the naming conventions! 🙏

@zomars zomars added the core area: core, team members only label Jul 20, 2023
Comment thread apps/web/playwright/login.2fa.e2e.ts Outdated

await expect(page.locator(`[data-testid=two-factor-switch][data-state="checked"]`)).toBeVisible();
await page.waitForSelector(`[data-testid=two-factor-switch]`);
await expect(page.locator(`[data-testid=two-factor-switch]`)).toBeTruthy();
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Rather than just waiting for the switch to appear. Also expect that it is set to true

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think this checks if it is checked- rather whether the locator for the switch is truthy, so whenever it's present. There's an isChecked param in page. though.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Jul 20, 2023

📦 Next.js Bundle Analysis for @calcom/web

This analysis was generated by the Next.js Bundle Analysis action. 🤖

This PR introduced no changes to the JavaScript bundle! 🙌

@deploysentinel
Copy link
Copy Markdown

deploysentinel Bot commented Jul 20, 2023

Current Playwright Test Results Summary

✅ 95 Passing - ⚠️ 2 Flaky

Run may still be in progress, this comment will be updated as current testing workflow or job completes...

(Last updated on 07/20/2023 07:40:28pm UTC)

Run Details

Running Workflow PR Update on Github Actions

Commit: f03d3b6

Started: 07/20/2023 07:38:25pm UTC

⚠️ Flakes

📄   packages/embeds/embed-core/playwright/tests/action-based.e2e.ts • 1 Flake

Test Case Results

Test Case Last 7 days Failures Last 7 days Flakes
Popup Tests should be able to reschedule
Retry 2Retry 1Initial Attempt
1.09% (2) 2 / 184 runs
failed over last 7 days
98.37% (181) 181 / 184 runs
flaked over last 7 days

📄   packages/app-store/routing-forms/playwright/tests/basic.e2e.ts • 1 Flake

Test Case Results

Test Case Last 7 days Failures Last 7 days Flakes
Routing Forms Seeded Routing Form Routing Link - Reporting and CSV Download
Retry 2Retry 1Initial Attempt
7.65% (15) 15 / 196 runs
failed over last 7 days
40.82% (80) 80 / 196 runs
flaked over last 7 days

View Detailed Build Results


Copy link
Copy Markdown
Contributor

@zomars zomars left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Noice

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

core area: core, team members only

Projects

No open projects
Status: No status

Development

Successfully merging this pull request may close these issues.

3 participants