• John Chen's avatar
    Reland "[ChromeDriver] Handle pauses in Perform Actions" · c368d9b6
    John Chen authored
    This is a reland of 70ffd447
    
    Original change was reverted due to test flakiness on Mac, caused by:
    * Pause time often goes above the upper limit of 300 ms, sometime more than
      double the limit.
    * Occasionally the first event is missing.
    
    The following changes are made to improve test reliability:
    * Remove the check of an upper limit for the pause time. With the wide range
      of actual pause time, there appears to be no feasible upper limit to use.
    * The first significant event is now pointer down instead of key down, to
      ensure that the target element receives focus. The previous dependence on
      autofocus attribute appears to be unreliable.
    * Change mouse button from 1 (middle) to 0 (left), as the middle mouse button
      triggers paste on some platforms. (It was a typo.)
    
    Original change's description:
    > [ChromeDriver] Handle pauses in Perform Actions
    >
    > W3C spec allows the app to specify pauses within Perform Actions command
    > (https://w3c.github.io/webdriver/#dfn-dispatch-actions). Updating
    > ChromeDriver to handle these pauses.
    >
    > Bug: chromedriver:1897
    > Change-Id: I533179f4a9f2216bfacf0f4fdb539c8f898bed07
    > Reviewed-on: https://chromium-review.googlesource.com/c/1392281
    > Commit-Queue: John Chen <johnchen@chromium.org>
    > Reviewed-by: Caleb Rouleau <crouleau@chromium.org>
    > Cr-Commit-Position: refs/heads/master@{#619506}
    
    Bug: chromedriver:1897
    Change-Id: I38122bdc01965345421429b1d2f45374395b0cc7
    Reviewed-on: https://chromium-review.googlesource.com/c/1394786Reviewed-by: default avatarCaleb Rouleau <crouleau@chromium.org>
    Commit-Queue: John Chen <johnchen@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#619717}
    c368d9b6
window_commands.cc 76.4 KB