Remove subtitles for the homepage IA
Remove the summary of the homepage IA if silky home enabled. Fixes: 170933968 Test: robotest & visual with turning on/off silky home Change-Id: I502b6590cece9b80e9923109fe0582cc4d9a1c56
This commit is contained in:
@@ -31,9 +31,12 @@ import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.content.pm.PackageManager;
|
||||
import android.content.pm.ResolveInfo;
|
||||
import android.util.FeatureFlagUtils;
|
||||
|
||||
import com.android.settings.R;
|
||||
import com.android.settings.core.FeatureFlags;
|
||||
|
||||
import org.junit.After;
|
||||
import org.junit.Before;
|
||||
import org.junit.Test;
|
||||
import org.junit.runner.RunWith;
|
||||
@@ -65,6 +68,13 @@ public class TopLevelDisplayPreferenceControllerTest {
|
||||
mController = new TopLevelDisplayPreferenceController(mContext, "test_key");
|
||||
}
|
||||
|
||||
@After
|
||||
public void tearDown() {
|
||||
if (FeatureFlagUtils.isEnabled(mContext, FeatureFlags.SILKY_HOME)) {
|
||||
FeatureFlagUtils.setEnabled(mContext, FeatureFlags.SILKY_HOME, false);
|
||||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
public void getAvailibilityStatus_availableByDefault() {
|
||||
assertThat(mController.getAvailabilityStatus()).isEqualTo(AVAILABLE);
|
||||
@@ -109,4 +119,11 @@ public class TopLevelDisplayPreferenceControllerTest {
|
||||
assertThat(mController.getSummary())
|
||||
.isEqualTo(mContext.getText(R.string.display_dashboard_nowallpaper_summary));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void getSummary_silkyHomeEnabled_shouldBeNull() {
|
||||
FeatureFlagUtils.setEnabled(mContext, FeatureFlags.SILKY_HOME, true);
|
||||
|
||||
assertThat(mController.getSummary()).isNull();
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user