Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove most waitForTimeout usage from the freetext editor integration tests #18041

Merged

Conversation

timvandermeij
Copy link
Contributor

@timvandermeij timvandermeij commented May 2, 2024

The commit messages contain more details about the individual changes.

Fixes a part of #17656.

@timvandermeij
Copy link
Contributor Author

/botio integrationtest

@moz-tools-bot
Copy link
Collaborator

From: Bot.io (Windows)


Received

Command cmd_integrationtest from @timvandermeij received. Current queue size: 0

Live output at: http://54.193.163.58:8877/0a1f10fb0fb77d8/output.txt

@moz-tools-bot
Copy link
Collaborator

From: Bot.io (Linux m4)


Received

Command cmd_integrationtest from @timvandermeij received. Current queue size: 0

Live output at: http://54.241.84.105:8877/32468a9cce24e6e/output.txt

@moz-tools-bot
Copy link
Collaborator

From: Bot.io (Linux m4)


Success

Full output at http://54.241.84.105:8877/32468a9cce24e6e/output.txt

Total script time: 7.25 mins

  • Integration Tests: Passed

@moz-tools-bot
Copy link
Collaborator

From: Bot.io (Windows)


Failed

Full output at http://54.193.163.58:8877/0a1f10fb0fb77d8/output.txt

Total script time: 21.14 mins

  • Integration Tests: FAILED

@timvandermeij
Copy link
Contributor Author

The Windows failure above is already tracked in #17931 and therefore unrelated to this PR.

…on tests

This commit replaces a `waitForTimeout` occurrence with an equivalent
`waitForSelector` expression, and removes two other `waitForTimeout`
occurrences that are obsolete because we already wait for an observable
event to trigger or class change to happen.

Note that the other `waitForTimeout` occurrences in this file are either
part of mozilla#17931 or remain until we find a good way to ensure that nothing
happened (because currently there is nothing we can await there).
This commit replaces `waitForFunction` calls that use
`document.activeElement` to wait for an element to get focus by simpler
`waitForSelector` expressions that use the `:focus` selector. Note that
we already use this in other tests, so this improves consistency too.
@timvandermeij timvandermeij force-pushed the integration-tests-timeout-freetext branch from 8f1a84e to bb74338 Compare May 6, 2024 17:35
Copy link
Contributor

@calixteman calixteman left a comment

Choose a reason for hiding this comment

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

LGTM. Thank you.

@timvandermeij timvandermeij merged commit 14e8746 into mozilla:master May 6, 2024
7 checks passed
@timvandermeij timvandermeij deleted the integration-tests-timeout-freetext branch May 6, 2024 18:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants