commit | 53a1d80ccfbb9cb7f9e02df14a88a35f4fcda7ab | [log] [tgz] |
---|---|---|
author | Treehugger Robot <treehugger-gerrit@google.com> | Thu Nov 09 22:49:41 2017 +0000 |
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | Thu Nov 09 22:49:41 2017 +0000 |
tree | 75caed34829eab9c4d1c9b25c9f4f033f2372e62 | |
parent | b5dc566e1c08a3f1805374ff444a47bc1b135701 [diff] | |
parent | 713addf614f59654666dc9725f6beee3e97dadc8 [diff] |
Merge "Adding waitForKeyguardShowingAndNotOccluded on Keyguard tests." into oreo-cts-dev
diff --git a/hostsidetests/services/activityandwindowmanager/activitymanager/src/android/server/cts/KeyguardTransitionTests.java b/hostsidetests/services/activityandwindowmanager/activitymanager/src/android/server/cts/KeyguardTransitionTests.java index 05065aa..4222159 100644 --- a/hostsidetests/services/activityandwindowmanager/activitymanager/src/android/server/cts/KeyguardTransitionTests.java +++ b/hostsidetests/services/activityandwindowmanager/activitymanager/src/android/server/cts/KeyguardTransitionTests.java
@@ -83,8 +83,8 @@ if (!isHandheld()) { return; } - launchActivity("ShowWhenLockedActivity"); gotoKeyguard(); + launchActivity("ShowWhenLockedActivity"); launchActivity("TestActivity"); mAmWmState.waitForKeyguardShowingAndNotOccluded(mDevice); mAmWmState.computeState(mDevice, null);
diff --git a/hostsidetests/services/activityandwindowmanager/util/src/android/server/cts/ActivityManagerTestBase.java b/hostsidetests/services/activityandwindowmanager/util/src/android/server/cts/ActivityManagerTestBase.java index a6d4226..f732b05 100644 --- a/hostsidetests/services/activityandwindowmanager/util/src/android/server/cts/ActivityManagerTestBase.java +++ b/hostsidetests/services/activityandwindowmanager/util/src/android/server/cts/ActivityManagerTestBase.java
@@ -663,9 +663,10 @@ runCommandAndPrintOutput("input keyevent KEYCODE_ENTER"); } - protected void gotoKeyguard() throws DeviceNotAvailableException { + protected void gotoKeyguard() throws Exception { sleepDevice(); wakeUpDevice(); + mAmWmState.waitForKeyguardShowingAndNotOccluded(mDevice); } protected void setLockCredential() throws DeviceNotAvailableException {