| 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 "chrome/browser/chromeos/kiosk_mode/kiosk_mode_idle_logout.h" | 5 #include "chrome/browser/chromeos/kiosk_mode/kiosk_mode_idle_logout.h" |
| 6 | 6 |
| 7 #include "ash/shell.h" | 7 #include "ash/shell.h" |
| 8 #include "ash/test/ash_test_base.h" | 8 #include "ash/test/ash_test_base.h" |
| 9 #include "ash/wm/user_activity_detector.h" | 9 #include "ash/wm/user_activity_detector.h" |
| 10 #include "base/bind.h" | 10 #include "base/bind.h" |
| 11 #include "base/memory/scoped_ptr.h" | 11 #include "base/memory/scoped_ptr.h" |
| 12 #include "base/message_loop/message_loop.h" | 12 #include "base/message_loop/message_loop.h" |
| 13 #include "base/synchronization/waitable_event.h" | 13 #include "base/synchronization/waitable_event.h" |
| 14 #include "chrome/browser/chrome_notification_types.h" | 14 #include "chrome/browser/chrome_notification_types.h" |
| 15 #include "chrome/browser/chromeos/login/user_manager.h" | 15 #include "chrome/browser/chromeos/login/user_manager.h" |
| 16 #include "chrome/browser/chromeos/settings/device_settings_test_helper.h" | 16 #include "chrome/browser/chromeos/settings/device_settings_test_helper.h" |
| 17 #include "content/public/browser/browser_thread.h" | |
| 18 #include "content/public/browser/notification_registrar.h" | 17 #include "content/public/browser/notification_registrar.h" |
| 19 #include "content/public/browser/notification_service.h" | 18 #include "content/public/browser/notification_service.h" |
| 20 #include "testing/gtest/include/gtest/gtest.h" | 19 #include "testing/gtest/include/gtest/gtest.h" |
| 21 | 20 |
| 22 namespace chromeos { | 21 namespace chromeos { |
| 23 | 22 |
| 24 class KioskModeIdleLogoutTest : public ash::test::AshTestBase { | 23 class KioskModeIdleLogoutTest : public ash::test::AshTestBase { |
| 25 public: | 24 public: |
| 26 KioskModeIdleLogoutTest() | 25 KioskModeIdleLogoutTest() |
| 27 : idle_logout_(NULL) { | 26 : idle_logout_(NULL) { |
| (...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 70 // checking for the current logged in user in our observer anyway, giving | 69 // checking for the current logged in user in our observer anyway, giving |
| 71 // NoDetails here is fine. | 70 // NoDetails here is fine. |
| 72 content::NotificationService::NoDetails()); | 71 content::NotificationService::NoDetails()); |
| 73 | 72 |
| 74 RunAllPendingInMessageLoop(); | 73 RunAllPendingInMessageLoop(); |
| 75 EXPECT_FALSE(LoginUserObserverRegistered()); | 74 EXPECT_FALSE(LoginUserObserverRegistered()); |
| 76 EXPECT_TRUE(UserActivityObserverRegistered()); | 75 EXPECT_TRUE(UserActivityObserverRegistered()); |
| 77 } | 76 } |
| 78 | 77 |
| 79 } // namespace chromeos | 78 } // namespace chromeos |
| OLD | NEW |