OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 "ios/chrome/browser/ui/settings/passphrase_collection_view_controller_te
st.h" | 5 #import "ios/chrome/browser/ui/settings/passphrase_collection_view_controller_te
st.h" |
6 | 6 |
7 #import <UIKit/UIKit.h> | 7 #import <UIKit/UIKit.h> |
8 | 8 |
9 #include <memory> | 9 #include <memory> |
10 | 10 |
(...skipping 11 matching lines...) Expand all Loading... |
22 #import "ios/chrome/browser/signin/authentication_service_fake.h" | 22 #import "ios/chrome/browser/signin/authentication_service_fake.h" |
23 #include "ios/chrome/browser/sync/ios_chrome_profile_sync_service_factory.h" | 23 #include "ios/chrome/browser/sync/ios_chrome_profile_sync_service_factory.h" |
24 #include "ios/chrome/browser/sync/ios_chrome_profile_sync_test_util.h" | 24 #include "ios/chrome/browser/sync/ios_chrome_profile_sync_test_util.h" |
25 #include "ios/chrome/browser/sync/sync_setup_service.h" | 25 #include "ios/chrome/browser/sync/sync_setup_service.h" |
26 #include "ios/chrome/browser/sync/sync_setup_service_factory.h" | 26 #include "ios/chrome/browser/sync/sync_setup_service_factory.h" |
27 #import "ios/chrome/browser/ui/settings/settings_navigation_controller.h" | 27 #import "ios/chrome/browser/ui/settings/settings_navigation_controller.h" |
28 #import "ios/public/provider/chrome/browser/signin/fake_chrome_identity_service.
h" | 28 #import "ios/public/provider/chrome/browser/signin/fake_chrome_identity_service.
h" |
29 #import "testing/gtest_mac.h" | 29 #import "testing/gtest_mac.h" |
30 #include "testing/platform_test.h" | 30 #include "testing/platform_test.h" |
31 | 31 |
| 32 #if !defined(__has_feature) || !__has_feature(objc_arc) |
| 33 #error "This file requires ARC support." |
| 34 #endif |
| 35 |
32 using testing::DefaultValue; | 36 using testing::DefaultValue; |
33 using testing::NiceMock; | 37 using testing::NiceMock; |
34 using testing::Return; | 38 using testing::Return; |
35 | 39 |
36 std::unique_ptr<sync_preferences::PrefServiceSyncable> CreatePrefService() { | 40 std::unique_ptr<sync_preferences::PrefServiceSyncable> CreatePrefService() { |
37 sync_preferences::PrefServiceMockFactory factory; | 41 sync_preferences::PrefServiceMockFactory factory; |
38 scoped_refptr<user_prefs::PrefRegistrySyncable> registry( | 42 scoped_refptr<user_prefs::PrefRegistrySyncable> registry( |
39 new user_prefs::PrefRegistrySyncable); | 43 new user_prefs::PrefRegistrySyncable); |
40 std::unique_ptr<sync_preferences::PrefServiceSyncable> prefs = | 44 std::unique_ptr<sync_preferences::PrefServiceSyncable> prefs = |
41 factory.CreateSyncable(registry.get()); | 45 factory.CreateSyncable(registry.get()); |
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
100 | 104 |
101 void PassphraseCollectionViewControllerTest::SetUpNavigationController( | 105 void PassphraseCollectionViewControllerTest::SetUpNavigationController( |
102 UIViewController* test_controller) { | 106 UIViewController* test_controller) { |
103 dummy_controller_.reset([[UIViewController alloc] init]); | 107 dummy_controller_.reset([[UIViewController alloc] init]); |
104 nav_controller_.reset([[SettingsNavigationController alloc] | 108 nav_controller_.reset([[SettingsNavigationController alloc] |
105 initWithRootViewController:dummy_controller_ | 109 initWithRootViewController:dummy_controller_ |
106 browserState:chrome_browser_state_.get() | 110 browserState:chrome_browser_state_.get() |
107 delegate:nil]); | 111 delegate:nil]); |
108 [nav_controller_ pushViewController:test_controller animated:NO]; | 112 [nav_controller_ pushViewController:test_controller animated:NO]; |
109 } | 113 } |
OLD | NEW |