diff options
author | TreeHugger Robot <treehugger-gerrit@google.com> | 2019-10-03 17:56:50 +0000 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2019-10-03 17:56:50 +0000 |
commit | 055c22e8e658dcb87447a9c11ec492c2b8e922e5 (patch) | |
tree | e0c7334800aa34b2a1097a84007dac1483a10c7c | |
parent | a61914194e9b4be72683b643d29741f72f60e998 (diff) | |
parent | d7fdcab612d9c8136283ea432a24800a9cdbfdc8 (diff) | |
download | packages_apps_Trebuchet-055c22e8e658dcb87447a9c11ec492c2b8e922e5.tar.gz packages_apps_Trebuchet-055c22e8e658dcb87447a9c11ec492c2b8e922e5.tar.bz2 packages_apps_Trebuchet-055c22e8e658dcb87447a9c11ec492c2b8e922e5.zip |
Merge "correct naming and add comments for test case of custom shortcut." into ub-launcher3-qt-future-dev
-rw-r--r-- | tests/AndroidManifest-common.xml | 2 | ||||
-rw-r--r-- | tests/src/com/android/launcher3/testcomponent/CustomShortcutConfigActivity.java (renamed from tests/src/com/android/launcher3/testcomponent/ShortcutWidgetConfigActivity.java) | 6 | ||||
-rw-r--r-- | tests/src/com/android/launcher3/ui/TaplTestsLauncher3.java | 11 |
3 files changed, 15 insertions, 4 deletions
diff --git a/tests/AndroidManifest-common.xml b/tests/AndroidManifest-common.xml index 6802152c7..ffa90b9c5 100644 --- a/tests/AndroidManifest-common.xml +++ b/tests/AndroidManifest-common.xml @@ -62,7 +62,7 @@ <action android:name="android.appwidget.action.APPWIDGET_CONFIGURE"/> </intent-filter> </activity> - <activity android:name="com.android.launcher3.testcomponent.ShortcutWidgetConfigActivity"> + <activity android:name="com.android.launcher3.testcomponent.CustomShortcutConfigActivity"> <intent-filter> <action android:name="android.intent.action.CREATE_SHORTCUT" /> <category android:name="android.intent.category.DEFAULT" /> diff --git a/tests/src/com/android/launcher3/testcomponent/ShortcutWidgetConfigActivity.java b/tests/src/com/android/launcher3/testcomponent/CustomShortcutConfigActivity.java index f9d5f2d43..b673faa6f 100644 --- a/tests/src/com/android/launcher3/testcomponent/ShortcutWidgetConfigActivity.java +++ b/tests/src/com/android/launcher3/testcomponent/CustomShortcutConfigActivity.java @@ -27,7 +27,11 @@ import com.android.launcher3.R; import java.util.UUID; -public class ShortcutWidgetConfigActivity extends BaseTestingActivity { +/** + * A custom shortcut is a 1x1 widget that launches a specific intent when user tap on it. + * Custom shortcuts are replaced by deep shortcuts after api 25. + */ +public class CustomShortcutConfigActivity extends BaseTestingActivity { @Override protected void onCreate(Bundle savedInstanceState) { diff --git a/tests/src/com/android/launcher3/ui/TaplTestsLauncher3.java b/tests/src/com/android/launcher3/ui/TaplTestsLauncher3.java index 38dba1628..709822bbb 100644 --- a/tests/src/com/android/launcher3/ui/TaplTestsLauncher3.java +++ b/tests/src/com/android/launcher3/ui/TaplTestsLauncher3.java @@ -342,10 +342,17 @@ public class TaplTestsLauncher3 extends AbstractLauncherUiTest { } } + /** + * Test dragging a custom shortcut to the workspace and launch it. + * + * A custom shortcut is a 1x1 widget that launches a specific intent when user tap on it. + * Custom shortcuts are replaced by deep shortcuts after api 25. + */ @Test - public void testDragShortcutWidget() { + @PortraitLandscape + public void testDragCustomShortcut() { mLauncher.getWorkspace().openAllWidgets() - .getWidget("com.android.launcher3.testcomponent.ShortcutWidgetConfigActivity") + .getWidget("com.android.launcher3.testcomponent.CustomShortcutConfigActivity") .dragToWorkspace(); mLauncher.getWorkspace().getWorkspaceAppIcon("Shortcut") .launch(getAppPackageName()); |