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 "ash/common/system/tray/system_tray.h" | 5 #include "ash/common/system/tray/system_tray.h" |
6 #include "ash/shell.h" | 6 #include "ash/shell.h" |
7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
8 #include "base/location.h" | 8 #include "base/location.h" |
9 #include "base/single_thread_task_runner.h" | 9 #include "base/single_thread_task_runner.h" |
10 #include "base/strings/string_util.h" | 10 #include "base/strings/string_util.h" |
(...skipping 206 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
217 // Verifies the cursor is not hidden at startup when running guest session. | 217 // Verifies the cursor is not hidden at startup when running guest session. |
218 IN_PROC_BROWSER_TEST_F(LoginGuestTest, CursorShown) { | 218 IN_PROC_BROWSER_TEST_F(LoginGuestTest, CursorShown) { |
219 EXPECT_TRUE(ash::Shell::GetInstance()->cursor_manager()->IsCursorVisible()); | 219 EXPECT_TRUE(ash::Shell::GetInstance()->cursor_manager()->IsCursorVisible()); |
220 | 220 |
221 TestSystemTrayIsVisible(); | 221 TestSystemTrayIsVisible(); |
222 } | 222 } |
223 | 223 |
224 // Verifies the cursor is hidden at startup on login screen. | 224 // Verifies the cursor is hidden at startup on login screen. |
225 IN_PROC_BROWSER_TEST_F(LoginCursorTest, CursorHidden) { | 225 IN_PROC_BROWSER_TEST_F(LoginCursorTest, CursorHidden) { |
226 // Login screen needs to be shown explicitly when running test. | 226 // Login screen needs to be shown explicitly when running test. |
227 ShowLoginWizard(WizardController::kLoginScreenName); | 227 ShowLoginWizard(OobeScreen::SCREEN_SPECIAL_LOGIN); |
228 | 228 |
229 // Cursor should be hidden at startup | 229 // Cursor should be hidden at startup |
230 EXPECT_FALSE(ash::Shell::GetInstance()->cursor_manager()->IsCursorVisible()); | 230 EXPECT_FALSE(ash::Shell::GetInstance()->cursor_manager()->IsCursorVisible()); |
231 | 231 |
232 // Cursor should be shown after cursor is moved. | 232 // Cursor should be shown after cursor is moved. |
233 EXPECT_TRUE(ui_test_utils::SendMouseMoveSync(gfx::Point())); | 233 EXPECT_TRUE(ui_test_utils::SendMouseMoveSync(gfx::Point())); |
234 EXPECT_TRUE(ash::Shell::GetInstance()->cursor_manager()->IsCursorVisible()); | 234 EXPECT_TRUE(ash::Shell::GetInstance()->cursor_manager()->IsCursorVisible()); |
235 | 235 |
236 base::ThreadTaskRunnerHandle::Get()->DeleteSoon( | 236 base::ThreadTaskRunnerHandle::Get()->DeleteSoon( |
237 FROM_HERE, LoginDisplayHost::default_host()); | 237 FROM_HERE, LoginDisplayHost::default_host()); |
(...skipping 21 matching lines...) Expand all Loading... |
259 content::WindowedNotificationObserver session_start_waiter( | 259 content::WindowedNotificationObserver session_start_waiter( |
260 chrome::NOTIFICATION_SESSION_STARTED, | 260 chrome::NOTIFICATION_SESSION_STARTED, |
261 content::NotificationService::AllSources()); | 261 content::NotificationService::AllSources()); |
262 SubmitGaiaAuthOfflineForm(kTestUser, kPassword); | 262 SubmitGaiaAuthOfflineForm(kTestUser, kPassword); |
263 session_start_waiter.Wait(); | 263 session_start_waiter.Wait(); |
264 | 264 |
265 TestSystemTrayIsVisible(); | 265 TestSystemTrayIsVisible(); |
266 } | 266 } |
267 | 267 |
268 } // namespace chromeos | 268 } // namespace chromeos |
OLD | NEW |