OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #import <XCTest/XCTest.h> | 5 #import <XCTest/XCTest.h> |
6 | 6 |
7 #include "base/mac/bind_objc_block.h" | 7 #include "base/mac/bind_objc_block.h" |
8 #import "ios/chrome/browser/ui/tools_menu/tools_menu_view_controller.h" | 8 #import "ios/chrome/browser/ui/tools_menu/tools_menu_view_controller.h" |
9 #include "ios/chrome/grit/ios_strings.h" | 9 #include "ios/chrome/grit/ios_strings.h" |
10 #import "ios/chrome/test/app/web_view_interaction_test_util.h" | 10 #import "ios/chrome/test/app/web_view_interaction_test_util.h" |
(...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
138 performAction:grey_tap()]; | 138 performAction:grey_tap()]; |
139 | 139 |
140 // Tap on the 'George Washington' result. | 140 // Tap on the 'George Washington' result. |
141 NSString* cellLabel = address; | 141 NSString* cellLabel = address; |
142 [[EarlGrey selectElementWithMatcher:grey_accessibilityLabel(cellLabel)] | 142 [[EarlGrey selectElementWithMatcher:grey_accessibilityLabel(cellLabel)] |
143 performAction:grey_tap()]; | 143 performAction:grey_tap()]; |
144 } | 144 } |
145 | 145 |
146 // Close the settings. | 146 // Close the settings. |
147 - (void)exitSettingsMenu { | 147 - (void)exitSettingsMenu { |
148 NSString* backButtonA11yId = @"back_bar_button"; | 148 NSString* backButtonA11yId = @"ic_arrow_back"; |
149 [[EarlGrey | 149 [[EarlGrey |
150 selectElementWithMatcher:grey_allOf( | 150 selectElementWithMatcher:grey_allOf( |
151 grey_accessibilityID(backButtonA11yId), | 151 grey_accessibilityID(backButtonA11yId), |
152 grey_accessibilityTrait( | 152 grey_accessibilityTrait( |
153 UIAccessibilityTraitButton), | 153 UIAccessibilityTraitButton), |
154 nil)] performAction:grey_tap()]; | 154 nil)] performAction:grey_tap()]; |
155 [[EarlGrey | 155 [[EarlGrey |
156 selectElementWithMatcher:grey_allOf( | 156 selectElementWithMatcher:grey_allOf( |
157 grey_accessibilityID(backButtonA11yId), | 157 grey_accessibilityID(backButtonA11yId), |
158 grey_accessibilityTrait( | 158 grey_accessibilityTrait( |
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
216 stringWithFormat:@"%@, %@", l10n_util::GetNSString( | 216 stringWithFormat:@"%@, %@", l10n_util::GetNSString( |
217 IDS_IOS_AUTOFILL_COUNTRY), | 217 IDS_IOS_AUTOFILL_COUNTRY), |
218 expectation.expected_result])] | 218 expectation.expected_result])] |
219 assertWithMatcher:grey_notNil()]; | 219 assertWithMatcher:grey_notNil()]; |
220 } | 220 } |
221 | 221 |
222 [self exitSettingsMenu]; | 222 [self exitSettingsMenu]; |
223 } | 223 } |
224 | 224 |
225 @end | 225 @end |
OLD | NEW |