commit | fa8bd1e5eab31956cfc121d1ab3c689f496f4ab2 | [log] [tgz] |
---|---|---|
author | Diksha Gohlyan <dikshag@google.com> | Wed Nov 18 23:48:06 2020 +0000 |
committer | Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com> | Wed Nov 18 23:48:06 2020 +0000 |
tree | 2094a5f4d44169c0e91c5766796658eb71c7b533 | |
parent | b281bd6b03656ca03875472cf54f70daa6f2f7a9 [diff] | |
parent | 91bc9d90125254b54c0d18b983e205c038573249 [diff] |
Wakeup and unlock screen before running the tests am: 91bc9d9012 Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/DocumentsUI/+/13080688 Change-Id: I1467d93fd1cde07a4c99905324b50adcc6739227
diff --git a/tests/functional/com/android/documentsui/ActivityTest.java b/tests/functional/com/android/documentsui/ActivityTest.java index 65271d0..ec4e6cb 100644 --- a/tests/functional/com/android/documentsui/ActivityTest.java +++ b/tests/functional/com/android/documentsui/ActivityTest.java
@@ -32,6 +32,7 @@ import android.support.test.uiautomator.UiDevice; import android.support.test.uiautomator.UiObjectNotFoundException; import android.test.ActivityInstrumentationTestCase2; +import android.view.KeyEvent; import android.view.MotionEvent; import com.android.documentsui.base.Features; @@ -125,6 +126,8 @@ getTestingProviderAuthority()); device.setOrientationNatural(); + device.pressKeyCode(KeyEvent.KEYCODE_WAKEUP); + device.pressKeyCode(KeyEvent.KEYCODE_MENU); setupTestingRoots(); launchActivity();