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 <EarlGrey/EarlGrey.h> | 5 #import <EarlGrey/EarlGrey.h> |
6 #import <XCTest/XCTest.h> | 6 #import <XCTest/XCTest.h> |
7 | 7 |
8 #import "ios/chrome/browser/ui/settings/settings_collection_view_controller.h" | 8 #import "ios/chrome/browser/ui/settings/settings_collection_view_controller.h" |
9 #include "ios/chrome/browser/ui/tools_menu/tools_menu_constants.h" | 9 #include "ios/chrome/browser/ui/tools_menu/tools_menu_constants.h" |
10 #import "ios/chrome/browser/ui/tools_menu/tools_popup_controller.h" | 10 #import "ios/chrome/browser/ui/tools_menu/tools_popup_controller.h" |
11 #include "ios/chrome/grit/ios_strings.h" | 11 #include "ios/chrome/grit/ios_strings.h" |
12 #include "ios/chrome/test/earl_grey/accessibility_util.h" | 12 #include "ios/chrome/test/earl_grey/accessibility_util.h" |
13 #import "ios/chrome/test/earl_grey/chrome_earl_grey_ui.h" | 13 #import "ios/chrome/test/earl_grey/chrome_earl_grey_ui.h" |
14 #import "ios/chrome/test/earl_grey/chrome_matchers.h" | 14 #import "ios/chrome/test/earl_grey/chrome_matchers.h" |
15 #import "ios/chrome/test/earl_grey/chrome_test_case.h" | 15 #import "ios/chrome/test/earl_grey/chrome_test_case.h" |
16 | 16 |
| 17 #if !defined(__has_feature) || !__has_feature(objc_arc) |
| 18 #error "This file requires ARC support." |
| 19 #endif |
| 20 |
17 using chrome_test_util::NavigationBarDoneButton; | 21 using chrome_test_util::NavigationBarDoneButton; |
18 | 22 |
19 namespace { | 23 namespace { |
20 // Displacement for scroll action. | 24 // Displacement for scroll action. |
21 const CGFloat kScrollDisplacement = 50.0; | 25 const CGFloat kScrollDisplacement = 50.0; |
22 } // namespace | 26 } // namespace |
23 @interface TranslateUITestCase : ChromeTestCase | 27 @interface TranslateUITestCase : ChromeTestCase |
24 @end | 28 @end |
25 | 29 |
26 @implementation TranslateUITestCase | 30 @implementation TranslateUITestCase |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
68 selectElementWithMatcher:grey_allOf( | 72 selectElementWithMatcher:grey_allOf( |
69 grey_accessibilityID(@"ic_arrow_back"), | 73 grey_accessibilityID(@"ic_arrow_back"), |
70 grey_accessibilityTrait( | 74 grey_accessibilityTrait( |
71 UIAccessibilityTraitButton), | 75 UIAccessibilityTraitButton), |
72 nil)] performAction:grey_tap()]; | 76 nil)] performAction:grey_tap()]; |
73 [[EarlGrey selectElementWithMatcher:NavigationBarDoneButton()] | 77 [[EarlGrey selectElementWithMatcher:NavigationBarDoneButton()] |
74 performAction:grey_tap()]; | 78 performAction:grey_tap()]; |
75 } | 79 } |
76 | 80 |
77 @end | 81 @end |
OLD | NEW |