| OLD | NEW |
| 1 // Copyright (c) 2017 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2017 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 "chrome/browser/chromeos/login/enrollment/enrollment_screen.h" | 5 #include "chrome/browser/chromeos/login/enrollment/enrollment_screen.h" |
| 6 #include "base/bind.h" | 6 #include "base/bind.h" |
| 7 #include "base/callback.h" | 7 #include "base/callback.h" |
| 8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
| 9 #include "base/message_loop/message_loop.h" | 9 #include "base/message_loop/message_loop.h" |
| 10 #include "base/test/scoped_mock_time_message_loop_task_runner.h" | 10 #include "base/test/scoped_mock_time_message_loop_task_runner.h" |
| (...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 191 EnterpriseEnrollmentHelper::SetupEnrollmentHelperMock( | 191 EnterpriseEnrollmentHelper::SetupEnrollmentHelperMock( |
| 192 &EnrollmentScreenUnitTest::MockEnrollmentHelperCreator<true>); | 192 &EnrollmentScreenUnitTest::MockEnrollmentHelperCreator<true>); |
| 193 | 193 |
| 194 SetUpEnrollmentScreen(); | 194 SetUpEnrollmentScreen(); |
| 195 | 195 |
| 196 // Set up expectation for BaseScreenDelegate::OnExit to be called | 196 // Set up expectation for BaseScreenDelegate::OnExit to be called |
| 197 // with BaseScreenDelegate::ENTERPRISE_ENROLLMENT_COMPLETED | 197 // with BaseScreenDelegate::ENTERPRISE_ENROLLMENT_COMPLETED |
| 198 // This is how we check that the code finishes and cleanly exits | 198 // This is how we check that the code finishes and cleanly exits |
| 199 // the enterprise enrollment flow. | 199 // the enterprise enrollment flow. |
| 200 EXPECT_CALL(*GetBaseScreenDelegate(), | 200 EXPECT_CALL(*GetBaseScreenDelegate(), |
| 201 OnExit(_, BaseScreenDelegate::ENTERPRISE_ENROLLMENT_COMPLETED, _)) | 201 OnExit(_, ScreenExitCode::ENTERPRISE_ENROLLMENT_COMPLETED, _)) |
| 202 .Times(1); | 202 .Times(1); |
| 203 | 203 |
| 204 // Start zero-touch enrollment. | 204 // Start zero-touch enrollment. |
| 205 enrollment_screen_->Show(); | 205 enrollment_screen_->Show(); |
| 206 } | 206 } |
| 207 } // namespace chromeos | 207 } // namespace chromeos |
| OLD | NEW |