Limit the suggestions to be shown to 5.
- when creating the dashboard data, pass the sublist of suggestions to cap the total number of suggestions to be shown to 5. - if user swipe away the suggestion, it will only remove the suggestion from the suggestion adapater, and will not trigger rebuilding the whole UI. Bug: 64072051 Change-Id: I1efabeb2a805c670007c631d3ccb0fdfbde7b55a Fix: 63309218 Test: make RunSettingsRoboTests
This commit is contained in:
@@ -118,9 +118,8 @@ public class DashboardSummaryTest {
|
||||
}
|
||||
|
||||
@Test
|
||||
public void onSuggestionDismissed_categoryShouldBeRefreshed() {
|
||||
doNothing().when(mSummary).rebuildUI();
|
||||
public void onSuggestionDismissed_shouldNotRebuildUI() {
|
||||
mSummary.onSuggestionDismissed(mock(Tile.class));
|
||||
verify(mSummary).rebuildUI();
|
||||
verify(mSummary, never()).rebuildUI();
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user