-
Notifications
You must be signed in to change notification settings - Fork 3.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This code was previously doing this: let wait_click = new Promise(resolve => { button.addEventListener("click", resolve)); }; return test_driver.click(button) .then(wait_click) .then(... but the argument to `.then(wait_click)` isn't a function, it's the promise to return. Therefore .then() creates an already-resolved promise containing `wait_click` as its resolved value. Which the next `.then()` block ignores. So this wasn't actually waiting for the click to occur. This triggered a number of test bugs (caused by erroneous assumptions accidentally baked into the tests. I fixed a few, and filed a few bugs for the rest (after failing to figure out how to fix them). Note that the WPT version of testdriver.js is rolled into Chromium, so that change is being made here: #49691 Bug: 384009734,384050894 Change-Id: Ibdb8a97d23998ad89c5a48c23a7e780dc605283b Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6094526 Reviewed-by: Jonathan Lee <[email protected]> Auto-Submit: Mason Freed <[email protected]> Commit-Queue: Mason Freed <[email protected]> Commit-Queue: Jonathan Lee <[email protected]> Cr-Commit-Position: refs/heads/main@{#1397010}
- Loading branch information
1 parent
0a38a00
commit 61bf26b
Showing
3 changed files
with
28 additions
and
27 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters