Commit 1ae65597 authored by Gauthier Ambard's avatar Gauthier Ambard Committed by Commit Bot

[iOS] Fix testNoSearchForPDF on iPhone SE

The test was failing because the screen of the phone is too small to
display the action now that the "Downloads" entry is displayed.
Fix it be scrolling the menu.

Fixed: 1079185
Change-Id: I787bfeb9fdbcc183a247241d9f4cbe04489dd852
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2187490
Auto-Submit: Gauthier Ambard <gambard@chromium.org>
Commit-Queue: Robbie Gibson <rkgibson@google.com>
Reviewed-by: default avatarRobbie Gibson <rkgibson@google.com>
Cr-Commit-Position: refs/heads/master@{#766372}
parent a6723dbb
...@@ -171,8 +171,12 @@ const char kPDFURL[] = "http://ios/testing/data/http_server_files/testpage.pdf"; ...@@ -171,8 +171,12 @@ const char kPDFURL[] = "http://ios/testing/data/http_server_files/testpage.pdf";
// Navigate to a mock pdf and verify that the find button is disabled. // Navigate to a mock pdf and verify that the find button is disabled.
[ChromeEarlGrey loadURL:URL]; [ChromeEarlGrey loadURL:URL];
[ChromeEarlGreyUI openToolsMenu]; [ChromeEarlGreyUI openToolsMenu];
[[EarlGrey [[[EarlGrey
selectElementWithMatcher:grey_accessibilityID(kToolsMenuFindInPageId)] selectElementWithMatcher:grey_allOf(
grey_accessibilityID(kToolsMenuFindInPageId),
grey_sufficientlyVisible(), nil)]
usingSearchAction:grey_scrollInDirection(kGREYDirectionDown, 200)
onElementWithMatcher:grey_accessibilityID(kPopupMenuToolsMenuTableViewId)]
assertWithMatcher:grey_accessibilityTrait( assertWithMatcher:grey_accessibilityTrait(
UIAccessibilityTraitNotEnabled)]; UIAccessibilityTraitNotEnabled)];
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment