Merge "More diagnostics for dragging failures in the lab, now for OOP tests" into ub-launcher3-qt-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
5235a8867b
@@ -111,6 +111,14 @@ public class TestInformationProvider extends ContentProvider {
|
||||
response.putInt(TestProtocol.TEST_INFO_RESPONSE_FIELD, (int) distance);
|
||||
break;
|
||||
}
|
||||
|
||||
case TestProtocol.REQUEST_ENABLE_DRAG_LOGGING:
|
||||
TestProtocol.sDebugTracing = true;
|
||||
break;
|
||||
|
||||
case TestProtocol.REQUEST_DISABLE_DRAG_LOGGING:
|
||||
TestProtocol.sDebugTracing = false;
|
||||
break;
|
||||
}
|
||||
return response;
|
||||
}
|
||||
|
||||
@@ -66,4 +66,6 @@ public final class TestProtocol {
|
||||
|
||||
public static boolean sDebugTracing = false;
|
||||
public static final String NO_DRAG_TAG = "b/129434166";
|
||||
public static final String REQUEST_ENABLE_DRAG_LOGGING = "enable-drag-logging";
|
||||
public static final String REQUEST_DISABLE_DRAG_LOGGING = "disable-drag-logging";
|
||||
}
|
||||
|
||||
@@ -142,6 +142,7 @@ public final class Workspace extends Home {
|
||||
static void dragIconToWorkspace(
|
||||
LauncherInstrumentation launcher, Launchable launchable, Point dest,
|
||||
String longPressIndicator) {
|
||||
launcher.getTestInfo(TestProtocol.REQUEST_ENABLE_DRAG_LOGGING);
|
||||
LauncherInstrumentation.log("dragIconToWorkspace: begin");
|
||||
final Point launchableCenter = launchable.getObject().getVisibleCenter();
|
||||
final long downTime = SystemClock.uptimeMillis();
|
||||
@@ -152,6 +153,7 @@ public final class Workspace extends Home {
|
||||
downTime, SystemClock.uptimeMillis(), MotionEvent.ACTION_UP, dest);
|
||||
LauncherInstrumentation.log("dragIconToWorkspace: end");
|
||||
launcher.waitUntilGone("drop_target_bar");
|
||||
launcher.getTestInfo(TestProtocol.REQUEST_DISABLE_DRAG_LOGGING);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user