OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 #include <string> | 5 #include <string> |
6 | 6 |
7 #include "base/compiler_specific.h" | 7 #include "base/compiler_specific.h" |
8 #include "base/macros.h" | 8 #include "base/macros.h" |
9 #include "base/run_loop.h" | 9 #include "base/run_loop.h" |
10 #include "base/strings/utf_string_conversions.h" | 10 #include "base/strings/utf_string_conversions.h" |
11 #include "base/threading/sequenced_worker_pool.h" | 11 #include "base/threading/sequenced_worker_pool.h" |
12 #include "chrome/browser/chrome_notification_types.h" | 12 #include "chrome/browser/chrome_notification_types.h" |
13 #include "chrome/browser/chromeos/login/login_manager_test.h" | 13 #include "chrome/browser/chromeos/login/login_manager_test.h" |
14 #include "chrome/browser/chromeos/login/startup_utils.h" | 14 #include "chrome/browser/chromeos/login/startup_utils.h" |
15 #include "chrome/browser/chromeos/login/supervised/supervised_user_authenticatio
n.h" | 15 #include "chrome/browser/chromeos/login/supervised/supervised_user_authenticatio
n.h" |
16 #include "chrome/browser/chromeos/login/supervised/supervised_user_test_base.h" | 16 #include "chrome/browser/chromeos/login/supervised/supervised_user_test_base.h" |
17 #include "chrome/browser/chromeos/login/ui/login_display_host_impl.h" | 17 #include "chrome/browser/chromeos/login/ui/login_display_host_impl.h" |
18 #include "chrome/browser/chromeos/login/ui/webui_login_view.h" | 18 #include "chrome/browser/chromeos/login/ui/webui_login_view.h" |
19 #include "chrome/browser/chromeos/login/users/chrome_user_manager.h" | 19 #include "chrome/browser/chromeos/login/users/chrome_user_manager.h" |
20 #include "chrome/browser/chromeos/login/users/supervised_user_manager.h" | 20 #include "chrome/browser/chromeos/login/users/supervised_user_manager.h" |
21 #include "chrome/browser/chromeos/net/network_portal_detector_test_impl.h" | 21 #include "chrome/browser/chromeos/net/network_portal_detector_test_impl.h" |
22 #include "chrome/browser/chromeos/settings/stub_cros_settings_provider.h" | 22 #include "chrome/browser/chromeos/settings/stub_cros_settings_provider.h" |
23 #include "chrome/browser/supervised_user/supervised_user_constants.h" | 23 #include "chrome/browser/supervised_user/supervised_user_constants.h" |
24 #include "chromeos/cryptohome/mock_async_method_caller.h" | 24 #include "chromeos/cryptohome/mock_async_method_caller.h" |
25 #include "chromeos/cryptohome/mock_homedir_methods.h" | 25 #include "chromeos/cryptohome/mock_homedir_methods.h" |
| 26 #include "components/sync/api/fake_sync_change_processor.h" |
| 27 #include "components/sync/api/sync_change.h" |
| 28 #include "components/sync/api/sync_error_factory_mock.h" |
| 29 #include "components/sync/core/attachments/attachment_service_proxy_for_test.h" |
| 30 #include "components/sync/protocol/sync.pb.h" |
26 #include "content/public/browser/notification_service.h" | 31 #include "content/public/browser/notification_service.h" |
27 #include "content/public/test/browser_test_utils.h" | 32 #include "content/public/test/browser_test_utils.h" |
28 #include "content/public/test/test_utils.h" | 33 #include "content/public/test/test_utils.h" |
29 #include "sync/api/fake_sync_change_processor.h" | |
30 #include "sync/api/sync_change.h" | |
31 #include "sync/api/sync_error_factory_mock.h" | |
32 #include "sync/internal_api/public/attachments/attachment_service_proxy_for_test
.h" | |
33 #include "sync/protocol/sync.pb.h" | |
34 | 34 |
35 using testing::_; | 35 using testing::_; |
36 using chromeos::SupervisedUserTestBase; | 36 using chromeos::SupervisedUserTestBase; |
37 using chromeos::kTestSupervisedUserDisplayName; | 37 using chromeos::kTestSupervisedUserDisplayName; |
38 using chromeos::kTestManager; | 38 using chromeos::kTestManager; |
39 | 39 |
40 namespace chromeos { | 40 namespace chromeos { |
41 | 41 |
42 class SupervisedUserPasswordTest : public SupervisedUserTestBase { | 42 class SupervisedUserPasswordTest : public SupervisedUserTestBase { |
43 public: | 43 public: |
(...skipping 208 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
252 // should be attempted. | 252 // should be attempted. |
253 IN_PROC_BROWSER_TEST_F(SupervisedUserPasswordTest, | 253 IN_PROC_BROWSER_TEST_F(SupervisedUserPasswordTest, |
254 PasswordChangeUserAndManagerTest) { | 254 PasswordChangeUserAndManagerTest) { |
255 EXPECT_CALL(*mock_homedir_methods_, MountEx(_, _, _, _)).Times(1); | 255 EXPECT_CALL(*mock_homedir_methods_, MountEx(_, _, _, _)).Times(1); |
256 EXPECT_CALL(*mock_homedir_methods_, UpdateKeyEx(_, _, _, _, _)).Times(0); | 256 EXPECT_CALL(*mock_homedir_methods_, UpdateKeyEx(_, _, _, _, _)).Times(0); |
257 SigninAsSupervisedUser(false, 1, kTestSupervisedUserDisplayName); | 257 SigninAsSupervisedUser(false, 1, kTestSupervisedUserDisplayName); |
258 testing::Mock::VerifyAndClearExpectations(mock_homedir_methods_); | 258 testing::Mock::VerifyAndClearExpectations(mock_homedir_methods_); |
259 } | 259 } |
260 | 260 |
261 } // namespace chromeos | 261 } // namespace chromeos |
OLD | NEW |