Revert "Add PowerSaveWhitelistExceptIdle as Optimizted modes condition"

This reverts commit 3f7839cad0.

Reason for revert: This fix will cause a side effect which makes app switch state from Unrestricted to Optimize then it will lock at Optimize mode only, will prepare other cl to fix the previous issue

Change-Id: Ic5232eb0099fa1591f15e72747eca4d08b9af9b9
This commit is contained in:
Wesley Wang
2021-10-14 09:31:13 +00:00
parent 3f7839cad0
commit b900e0e43b
10 changed files with 5 additions and 76 deletions

View File

@@ -745,16 +745,6 @@ public class AdvancedPowerUsageDetailTest {
.isEqualTo("This app requires optimized battery usage.");
}
@Test
public void testInitPreferenceForTriState_isAllowlistedExceptIdleApp_hasCorrectString() {
when(mBatteryOptimizeUtils.isAllowlistedExceptIdleApp()).thenReturn(true);
mFragment.initPreferenceForTriState(mContext);
assertThat(mFooterPreference.getTitle().toString())
.isEqualTo("This app requires optimized battery usage.");
}
@Test
public void testInitPreferenceForTriState_isSystemOrDefaultApp_hasCorrectString() {
when(mBatteryOptimizeUtils.isValidPackageName()).thenReturn(true);