Enable BindWidgetTest, RequestPinItemTest

Comparing only widget provider class names, as package names (sometimes)
switch to the test package, not to the ones in Launcher.

Bug: 131116593
Change-Id: Ieeed69432303a86fcefb194d509cdaf9d4513f3a
This commit is contained in:
vadimt
2019-05-03 12:56:13 -07:00
parent 7ff19aa560
commit 1bdb0f4046
4 changed files with 12 additions and 11 deletions

View File

@@ -80,7 +80,7 @@ public class RequestPinItemTest extends AbstractLauncherUiTest {
@Test
public void testEmpty() throws Throwable { /* needed while the broken tests are being fixed */ }
@Test @Ignore // b/131116593
@Test
public void testPinWidgetNoConfig() throws Throwable {
runTest("pinWidgetNoConfig", true, new ItemOperator() {
@Override
@@ -93,7 +93,7 @@ public class RequestPinItemTest extends AbstractLauncherUiTest {
});
}
@Test @Ignore // b/131116593
@Test
public void testPinWidgetNoConfig_customPreview() throws Throwable {
// Command to set custom preview
Intent command = RequestPinItemActivity.getCommandIntent(
@@ -111,7 +111,7 @@ public class RequestPinItemTest extends AbstractLauncherUiTest {
}, command);
}
@Test @Ignore // b/131116593
@Test
public void testPinWidgetWithConfig() throws Throwable {
runTest("pinWidgetWithConfig", true, new ItemOperator() {
@Override
@@ -124,7 +124,7 @@ public class RequestPinItemTest extends AbstractLauncherUiTest {
});
}
@Test @Ignore // b/131116593
@Test
public void testPinShortcut() throws Throwable {
// Command to set the shortcut id
Intent command = RequestPinItemActivity.getCommandIntent(
@@ -181,8 +181,7 @@ public class RequestPinItemTest extends AbstractLauncherUiTest {
// Accept confirmation:
BlockingBroadcastReceiver resultReceiver = new BlockingBroadcastReceiver(mCallbackAction);
mDevice.wait(Until.findObject(By.text(mTargetContext.getString(
R.string.place_automatically).toUpperCase())), DEFAULT_UI_TIMEOUT).click();
mDevice.wait(Until.findObject(By.text("Add automatically")), DEFAULT_UI_TIMEOUT).click();
Intent result = resultReceiver.blockingGetIntent();
assertNotNull(result);
mAppWidgetId = result.getIntExtra(AppWidgetManager.EXTRA_APPWIDGET_ID, -1);