From 5ff780520444330c1a13eb17a5c305e68d73b409 Mon Sep 17 00:00:00 2001 From: Yanting Yang Date: Sat, 20 Jun 2020 18:42:56 +0800 Subject: [PATCH] Fix flaky fail of ApplicationsStateRoboTest The flaky fail of ApplicationsStateRoboTest is affected by that we added a thread mechanism to load the app icon in the AppEntry constructor which is to improve the scrolling of App info page. There will have a default app icon if the thread finish before icon null assertion. In the latest design, the app icon null assertion is not required, therefore remove them to fix test fail. Fixes: 159402083 Test: robotests Change-Id: If2577292a42c653ae3c7bebe9392f4fb62365a44 --- .../settingslib/applications/ApplicationsStateRoboTest.java | 3 --- 1 file changed, 3 deletions(-) diff --git a/packages/SettingsLib/tests/robotests/src/com/android/settingslib/applications/ApplicationsStateRoboTest.java b/packages/SettingsLib/tests/robotests/src/com/android/settingslib/applications/ApplicationsStateRoboTest.java index 95a4f69b287ca..5efce4da970fc 100644 --- a/packages/SettingsLib/tests/robotests/src/com/android/settingslib/applications/ApplicationsStateRoboTest.java +++ b/packages/SettingsLib/tests/robotests/src/com/android/settingslib/applications/ApplicationsStateRoboTest.java @@ -341,7 +341,6 @@ public class ApplicationsStateRoboTest { assertThat(appEntries.size()).isEqualTo(1); AppEntry launchableEntry = findAppEntry(appEntries, 1); - assertThat(launchableEntry.icon).isNull(); assertThat(launchableEntry.hasLauncherEntry).isFalse(); assertThat(launchableEntry.size).isGreaterThan(0L); } @@ -360,7 +359,6 @@ public class ApplicationsStateRoboTest { assertThat(appEntries.size()).isEqualTo(1); AppEntry launchableEntry = findAppEntry(appEntries, 1); - assertThat(launchableEntry.icon).isNull(); assertThat(launchableEntry.hasLauncherEntry).isFalse(); assertThat(launchableEntry.size).isEqualTo(-1); assertThat(launchableEntry.isHomeApp).isTrue(); @@ -380,7 +378,6 @@ public class ApplicationsStateRoboTest { assertThat(appEntries.size()).isEqualTo(1); AppEntry launchableEntry = findAppEntry(appEntries, 1); - assertThat(launchableEntry.icon).isNull(); assertThat(launchableEntry.size).isEqualTo(-1); assertThat(launchableEntry.isHomeApp).isFalse(); assertThat(launchableEntry.hasLauncherEntry).isTrue();