Merge "Add enable-suggestion option via TestProcotol so that test can opt-in to show live suggestion" into tm-qpr-dev am: ac29981a42

Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/20158848

Change-Id: I6cf20bc024261f138bc845e17a40d330f6ecb524
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
Ling Wo
2022-10-21 21:58:07 +00:00
committed by Automerger Merge Worker
2 changed files with 5 additions and 0 deletions

View File

@@ -124,6 +124,7 @@ public final class TestProtocol {
"get-grid-task-size-rect-for-tablet";
public static final String REQUEST_GET_OVERVIEW_PAGE_SPACING = "get-overview-page-spacing";
public static final String REQUEST_ENABLE_ROTATION = "enable_rotation";
public static final String REQUEST_ENABLE_SUGGESTION = "enable-suggestion";
public static boolean sDebugTracing = false;
public static final String REQUEST_ENABLE_DEBUG_TRACING = "enable-debug-tracing";

View File

@@ -391,6 +391,10 @@ public final class LauncherInstrumentation {
getTestInfo(TestProtocol.REQUEST_ENABLE_ROTATION, Boolean.toString(on));
}
public void setEnableSuggestion(boolean enableSuggestion) {
getTestInfo(TestProtocol.REQUEST_ENABLE_SUGGESTION, Boolean.toString(enableSuggestion));
}
public boolean hadNontestEvents() {
return getTestInfo(TestProtocol.REQUEST_GET_HAD_NONTEST_EVENTS)
.getBoolean(TestProtocol.TEST_INFO_RESPONSE_FIELD);