commit | eb493d5d69482be0de4edba404e1ed359febc856 | [log] [tgz] |
---|---|---|
author | Fan Zhang <zhfan@google.com> | Tue Mar 05 13:19:26 2019 -0800 |
committer | Fan Zhang <zhfan@google.com> | Tue Mar 05 13:27:47 2019 -0800 |
tree | e7f15e362e2214a56340678d1d626ed88ef5171e | |
parent | 76b70687e7a0c3aafefd0605d680a6344a1d0e38 [diff] |
Wake up/unlock device before running tests Fixes: 127452134 Test: atest Change-Id: I627f848a080b4569b658678094d45576eab9247c
diff --git a/tests/unit/src/com/android/settings/core/LifecycleEventHandlingTest.java b/tests/unit/src/com/android/settings/core/LifecycleEventHandlingTest.java index e601171..57d5662 100644 --- a/tests/unit/src/com/android/settings/core/LifecycleEventHandlingTest.java +++ b/tests/unit/src/com/android/settings/core/LifecycleEventHandlingTest.java
@@ -50,8 +50,10 @@ private UiDevice mDevice; @Before - public void setUp() { + public void setUp() throws Exception { mDevice = UiDevice.getInstance(InstrumentationRegistry.getInstrumentation()); + mDevice.wakeUp(); + mDevice.executeShellCommand("wm dismiss-keyguard"); mContext = InstrumentationRegistry.getTargetContext(); mTargetPackage = mContext.getPackageName(); }