Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 2d49d1de authored by Vadim Tryshev's avatar Vadim Tryshev Committed by Android (Google) Code Review
Browse files

Merge "Fixing flakiness of widget tests" into ub-launcher3-qt-dev

parents c857ad80 0edb04ca
Loading
Loading
Loading
Loading
+3 −4
Original line number Diff line number Diff line
@@ -27,6 +27,7 @@ import android.graphics.Point;
import android.os.Process;
import android.os.SystemClock;
import android.util.Log;
import android.view.KeyEvent;
import android.view.MotionEvent;
import android.view.View;
import android.view.ViewGroup;
@@ -186,10 +187,8 @@ public class TestViewHelpers {
     */
    public static UiObject2 openWidgetsTray() {
        final UiDevice device = getDevice();
        device.pressMenu(); // Enter overview mode.
        device.wait(Until.findObject(
                By.text(getTargetContext().getString(R.string.widget_button_text))),
                AbstractLauncherUiTest.DEFAULT_UI_TIMEOUT).click();
        device.pressKeyCode(KeyEvent.KEYCODE_W, KeyEvent.META_CTRL_ON);
        device.waitForIdle();
        return findViewById(R.id.widgets_list_view);
    }