| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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/system/automatic_reboot_manager.h" | 5 #include "chrome/browser/chromeos/system/automatic_reboot_manager.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 #include <utility> | 8 #include <utility> |
| 9 | 9 |
| 10 #include "ash/shell.h" | 10 #include "ash/shell.h" |
| (...skipping 504 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 515 void AutomaticRebootManagerBasicTest:: | 515 void AutomaticRebootManagerBasicTest:: |
| 516 VerifyLoginScreenIdleTimerIsRunning() const { | 516 VerifyLoginScreenIdleTimerIsRunning() const { |
| 517 VerifyTimerIsRunning( | 517 VerifyTimerIsRunning( |
| 518 automatic_reboot_manager_->login_screen_idle_timer_.get(), | 518 automatic_reboot_manager_->login_screen_idle_timer_.get(), |
| 519 base::TimeDelta::FromSeconds(60)); | 519 base::TimeDelta::FromSeconds(60)); |
| 520 } | 520 } |
| 521 | 521 |
| 522 void AutomaticRebootManagerBasicTest::SetUpdateStatusNeedReboot() { | 522 void AutomaticRebootManagerBasicTest::SetUpdateStatusNeedReboot() { |
| 523 UpdateEngineClient::Status client_status; | 523 UpdateEngineClient::Status client_status; |
| 524 client_status.status = UpdateEngineClient::UPDATE_STATUS_UPDATED_NEED_REBOOT; | 524 client_status.status = UpdateEngineClient::UPDATE_STATUS_UPDATED_NEED_REBOOT; |
| 525 update_engine_client_->set_update_engine_client_status(client_status); | 525 update_engine_client_->set_default_status(client_status); |
| 526 } | 526 } |
| 527 | 527 |
| 528 AutomaticRebootManagerTest::AutomaticRebootManagerTest() { | 528 AutomaticRebootManagerTest::AutomaticRebootManagerTest() { |
| 529 is_user_logged_in_ = GetParam(); | 529 is_user_logged_in_ = GetParam(); |
| 530 } | 530 } |
| 531 | 531 |
| 532 AutomaticRebootManagerTest::~AutomaticRebootManagerTest() { | 532 AutomaticRebootManagerTest::~AutomaticRebootManagerTest() { |
| 533 } | 533 } |
| 534 | 534 |
| 535 // Chrome is showing the login screen. The current uptime is 12 hours. | 535 // Chrome is showing the login screen. The current uptime is 12 hours. |
| (...skipping 1199 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1735 // Verify that the device does not eventually reboot. | 1735 // Verify that the device does not eventually reboot. |
| 1736 FastForwardUntilNoTasksRemain(false); | 1736 FastForwardUntilNoTasksRemain(false); |
| 1737 } | 1737 } |
| 1738 | 1738 |
| 1739 INSTANTIATE_TEST_CASE_P(AutomaticRebootManagerTestInstance, | 1739 INSTANTIATE_TEST_CASE_P(AutomaticRebootManagerTestInstance, |
| 1740 AutomaticRebootManagerTest, | 1740 AutomaticRebootManagerTest, |
| 1741 ::testing::Bool()); | 1741 ::testing::Bool()); |
| 1742 | 1742 |
| 1743 } // namespace system | 1743 } // namespace system |
| 1744 } // namespace chromeos | 1744 } // namespace chromeos |
| OLD | NEW |