Skip to content

Conversation

@liamdebeasi
Copy link
Contributor

Pull request checklist

Please check if your PR fulfills the following requirements:

  • Tests for the changes have been added (for bug fixes / features)
  • Docs have been reviewed and added / updated if needed (for bug fixes / features)
    • Some docs updates need to be made in the ionic-docs repo, in a separate PR. See the contributing guide for details.
  • Build (npm run build) was run locally and any changes were pushed
  • Lint (npm run lint) has passed locally and any fixes were made for failures

Pull request type

Please check the type of change your PR introduces:

  • Bugfix
  • Feature
  • Code style update (formatting, renaming)
  • Refactoring (no functional changes, no api changes)
  • Build related changes
  • Documentation content changes
  • Other (please describe):

What is the current behavior?

Many of our assertions do not have the appropriate await causing certain test to be flaky. This is most often seen with focus tests where we need to test focus multiple times in a single test.

What is the new behavior?

Does this introduce a breaking change?

  • Yes
  • No

Other information

@github-actions github-actions bot added the package: core @ionic/core package label Jun 23, 2022
@liamdebeasi liamdebeasi marked this pull request as ready for review June 23, 2022 19:40
@liamdebeasi liamdebeasi requested a review from a team June 23, 2022 19:40
test.describe('modal: focus trapping', () => {
test.beforeEach(async ({ browserName }, testInfo) => {
test.skip(testInfo.project.metadata.rtl === true, 'This does not test LTR vs. RTL layout.');
test.skip(browserName === 'firefox', 'Firefox incorrectly allows keyboard focus to move to ion-content');
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This was flaky before, but now that we have the await in place it was failing more often. This appears to be a Firefox bug

Copy link
Contributor

@sean-perkins sean-perkins left a comment

Choose a reason for hiding this comment

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

Great discovery that these needed to be awaited.

@averyjohnston
Copy link
Contributor

Was the empty file at core/src/components/action-sheet/test/action-sheet.fixture.e2e.ts an intentional add? Should something be there?

@liamdebeasi
Copy link
Contributor Author

That was for something I was testing, but I forgot to remove the file. It's been removed now.

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

Labels

package: core @ionic/core package

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants