Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(576)

Unified Diff: ash/system/chromeos/power/power_event_observer_unittest.cc

Issue 2391153002: Converts most of WorkspaceLayoutManager tests to use common code (Closed)
Patch Set: merge Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ash/mus/test/wm_test_base.cc ('k') | ash/test/ash_test_base.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/system/chromeos/power/power_event_observer_unittest.cc
diff --git a/ash/system/chromeos/power/power_event_observer_unittest.cc b/ash/system/chromeos/power/power_event_observer_unittest.cc
index 15c9c6a970f4b4dceaac05fe0b21b8ede591f04f..7b82ef02e9624b92f9f6a641564e5bac5a88d122 100644
--- a/ash/system/chromeos/power/power_event_observer_unittest.cc
+++ b/ash/system/chromeos/power/power_event_observer_unittest.cc
@@ -8,6 +8,7 @@
#include "ash/shell.h"
#include "ash/test/ash_test_base.h"
+#include "ash/test/test_session_state_delegate.h"
#include "base/time/time.h"
#include "chromeos/dbus/dbus_thread_manager.h"
#include "chromeos/dbus/power_manager_client.h"
@@ -57,7 +58,7 @@ TEST_F(PowerEventObserverTest, LockBeforeSuspend) {
// Check that the observer requests a suspend-readiness callback when it hears
// that the system is about to suspend.
- SetCanLockScreen(true);
+ test::TestSessionStateDelegate::SetCanLockScreen(true);
SetShouldLockScreenBeforeSuspending(true);
observer_->SuspendImminent();
EXPECT_EQ(1, client->GetNumPendingSuspendReadinessCallbacks());
@@ -95,7 +96,7 @@ TEST_F(PowerEventObserverTest, SetInvisibleBeforeSuspend) {
// Tests that all the Compositors are marked invisible _after_ the screen lock
// animations have completed.
- SetCanLockScreen(true);
+ test::TestSessionStateDelegate::SetCanLockScreen(true);
SetShouldLockScreenBeforeSuspending(true);
observer_->SuspendImminent();
@@ -114,7 +115,7 @@ TEST_F(PowerEventObserverTest, SetInvisibleBeforeSuspend) {
TEST_F(PowerEventObserverTest, CanceledSuspend) {
// Tests that the Compositors are not marked invisible if a suspend is
// canceled or the system resumes before the lock screen is ready.
- SetCanLockScreen(true);
+ test::TestSessionStateDelegate::SetCanLockScreen(true);
SetShouldLockScreenBeforeSuspending(true);
observer_->SuspendImminent();
EXPECT_EQ(1, GetNumVisibleCompositors());
@@ -136,7 +137,7 @@ TEST_F(PowerEventObserverTest, DelayResuspendForLockAnimations) {
//
// In this case, the observer should block the second suspend request until
// the animations have completed.
- SetCanLockScreen(true);
+ test::TestSessionStateDelegate::SetCanLockScreen(true);
SetShouldLockScreenBeforeSuspending(true);
chromeos::PowerManagerClient* client =
« no previous file with comments | « ash/mus/test/wm_test_base.cc ('k') | ash/test/ash_test_base.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698