Commit aa9d3ee9 authored by Justin Cohen's avatar Justin Cohen Committed by Commit Bot

ios: Fix QRScanner close button matcher for iOS14.

Change-Id: I65c83fb0b39f64f106c867e68e19cd9d22c10fab
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2342642
Auto-Submit: Justin Cohen <justincohen@chromium.org>
Commit-Queue: Rohit Rao <rohitrao@chromium.org>
Reviewed-by: default avatarRohit Rao <rohitrao@chromium.org>
Cr-Commit-Position: refs/heads/master@{#796098}
parent 9fc0533e
...@@ -90,8 +90,9 @@ id<GREYMatcher> VisibleInteractableEnabled() { ...@@ -90,8 +90,9 @@ id<GREYMatcher> VisibleInteractableEnabled() {
// Returns the GREYMatcher for the button that closes the QR Scanner. // Returns the GREYMatcher for the button that closes the QR Scanner.
id<GREYMatcher> QrScannerCloseButton() { id<GREYMatcher> QrScannerCloseButton() {
return chrome_test_util::ButtonWithAccessibilityLabel( return grey_allOf(chrome_test_util::ButtonWithAccessibilityLabel(
QRScannerAppInterface.closeIconAccessibilityLabel); QRScannerAppInterface.closeIconAccessibilityLabel),
grey_userInteractionEnabled(), nil);
} }
// Returns the GREYMatcher for the button which indicates that torch is off and // Returns the GREYMatcher for the button which indicates that torch is off and
...@@ -227,12 +228,6 @@ void TapKeyboardReturnKeyInOmniboxWithText(std::string text) { ...@@ -227,12 +228,6 @@ void TapKeyboardReturnKeyInOmniboxWithText(std::string text) {
assertWithMatcher:VisibleInteractableEnabled()]; assertWithMatcher:VisibleInteractableEnabled()];
} }
// Checks that the close button is not visible.
- (void)assertCloseButtonIsNotVisible {
[[EarlGrey selectElementWithMatcher:QrScannerCloseButton()]
assertWithMatcher:grey_notVisible()];
}
// Checks that the torch off button is visible, interactable, and enabled, and // Checks that the torch off button is visible, interactable, and enabled, and
// that the torch on button is not. // that the torch on button is not.
- (void)assertTorchOffButtonIsVisible { - (void)assertTorchOffButtonIsVisible {
......
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