Fix b/265387286: The total percentage of all apps is not 100%

Bug: 265387286
Fix: 265387286
Test: manual
Change-Id: I654f8211a45c818f9a2d4867ac679e72c9ce6eb1
This commit is contained in:
Zaiyue Xue
2023-02-20 11:19:24 +08:00
parent 802bff9092
commit 6d939b34dc
14 changed files with 218 additions and 144 deletions

View File

@@ -145,7 +145,7 @@ public class AppBatteryPreferenceControllerTest {
mController.displayPreference(mScreen);
mBatteryDiffEntry.mConsumePower = 1;
mController.mBatteryDiffEntry = mBatteryDiffEntry;
when(mBatteryDiffEntry.getPercentOfTotal()).thenReturn(60.0);
when(mBatteryDiffEntry.getPercentage()).thenReturn(60.0);
mController.updateBatteryWithDiffEntry();