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

Commit 548d71a6 authored by Ben Lin's avatar Ben Lin
Browse files

Fix a broken test due to long press not done correctly in tests.

Long click no longer works/selects items for mouse clicks. We need to
change the toolType to finger for it to select items.

Change-Id: Ie43ab1d4ca5f44bb6e932b9a4638833045a6bcca
parent cbe7db1f
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -127,9 +127,12 @@ public class DirectoryListBot extends Bots.BaseBot {
    }

    public UiObject selectDocument(String label) throws UiObjectNotFoundException {
        int toolType = Configurator.getInstance().getToolType();
        Configurator.getInstance().setToolType(MotionEvent.TOOL_TYPE_FINGER);
        waitForDocument(label);
        UiObject doc = findDocument(label);
        doc.longClick();
        Configurator.getInstance().setToolType(toolType);
        return doc;
    }