OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "base/basictypes.h" | 5 #include "base/basictypes.h" |
6 #include "base/command_line.h" | 6 #include "base/command_line.h" |
7 #include "base/run_loop.h" | 7 #include "base/run_loop.h" |
8 #include "chrome/browser/chromeos/login/enrollment/enrollment_screen.h" | 8 #include "chrome/browser/chromeos/login/enrollment/enrollment_screen.h" |
9 #include "chrome/browser/chromeos/login/screens/mock_base_screen_delegate.h" | 9 #include "chrome/browser/chromeos/login/screens/mock_base_screen_delegate.h" |
10 #include "chrome/browser/chromeos/login/startup_utils.h" | 10 #include "chrome/browser/chromeos/login/startup_utils.h" |
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
82 static_cast<BaseScreen*>(enrollment_screen)->base_screen_delegate_ = | 82 static_cast<BaseScreen*>(enrollment_screen)->base_screen_delegate_ = |
83 WizardController::default_controller(); | 83 WizardController::default_controller(); |
84 } | 84 } |
85 | 85 |
86 class ProvisionedEnrollmentScreenTest : public EnrollmentScreenTest { | 86 class ProvisionedEnrollmentScreenTest : public EnrollmentScreenTest { |
87 public: | 87 public: |
88 ProvisionedEnrollmentScreenTest() {} | 88 ProvisionedEnrollmentScreenTest() {} |
89 | 89 |
90 private: | 90 private: |
91 // Overridden from InProcessBrowserTest: | 91 // Overridden from InProcessBrowserTest: |
92 virtual void SetUpCommandLine(base::CommandLine* command_line) override { | 92 void SetUpCommandLine(base::CommandLine* command_line) override { |
93 base::FilePath test_data_dir; | 93 base::FilePath test_data_dir; |
94 ASSERT_TRUE(chromeos::test_utils::GetTestDataPath( | 94 ASSERT_TRUE(chromeos::test_utils::GetTestDataPath( |
95 "app_mode", "kiosk_manifest", &test_data_dir)); | 95 "app_mode", "kiosk_manifest", &test_data_dir)); |
96 command_line->AppendSwitchPath( | 96 command_line->AppendSwitchPath( |
97 switches::kAppOemManifestFile, | 97 switches::kAppOemManifestFile, |
98 test_data_dir.AppendASCII("kiosk_manifest.json")); | 98 test_data_dir.AppendASCII("kiosk_manifest.json")); |
99 } | 99 } |
100 | 100 |
101 DISALLOW_COPY_AND_ASSIGN(ProvisionedEnrollmentScreenTest); | 101 DISALLOW_COPY_AND_ASSIGN(ProvisionedEnrollmentScreenTest); |
102 }; | 102 }; |
(...skipping 18 matching lines...) Expand all Loading... |
121 .WillOnce(InvokeWithoutArgs(&run_loop, &base::RunLoop::Quit)); | 121 .WillOnce(InvokeWithoutArgs(&run_loop, &base::RunLoop::Quit)); |
122 enrollment_screen->OnCancel(); | 122 enrollment_screen->OnCancel(); |
123 content::RunThisRunLoop(&run_loop); | 123 content::RunThisRunLoop(&run_loop); |
124 Mock::VerifyAndClearExpectations(&mock_base_screen_delegate); | 124 Mock::VerifyAndClearExpectations(&mock_base_screen_delegate); |
125 | 125 |
126 static_cast<BaseScreen*>(enrollment_screen)->base_screen_delegate_ = | 126 static_cast<BaseScreen*>(enrollment_screen)->base_screen_delegate_ = |
127 WizardController::default_controller(); | 127 WizardController::default_controller(); |
128 } | 128 } |
129 | 129 |
130 } // namespace chromeos | 130 } // namespace chromeos |
OLD | NEW |