private static final long TIME_EXPECTED_BACKGROUND = 6000;
private static final long TIME_EXPECTED_ALL = 7500;
private static final double BATTERY_SCREEN_USAGE = 300;
+ private static final double BATTERY_IDLE_USAGE = 600;
private static final double BATTERY_SYSTEM_USAGE = 600;
private static final double BATTERY_OVERACCOUNTED_USAGE = 500;
private static final double BATTERY_UNACCOUNTED_USAGE = 700;
private BatterySipper mSystemBatterySipper;
@Mock
private BatterySipper mCellBatterySipper;
+ @Mock
+ private BatterySipper mIdleBatterySipper;
@Mock(answer = Answers.RETURNS_DEEP_STUBS)
private Context mContext;
@Mock(answer = Answers.RETURNS_DEEP_STUBS)
mUnaccountedBatterySipper.drainType = BatterySipper.DrainType.UNACCOUNTED;
mUnaccountedBatterySipper.totalPowerMah = BATTERY_UNACCOUNTED_USAGE;
+ mIdleBatterySipper.drainType = BatterySipper.DrainType.IDLE;
+ mIdleBatterySipper.totalPowerMah = BATTERY_IDLE_USAGE;
+
mBatteryUtils = BatteryUtils.getInstance(RuntimeEnvironment.application);
mBatteryUtils.mPowerUsageFeatureProvider = mProvider;
sippers.add(mUnaccountedBatterySipper);
sippers.add(mWifiBatterySipper);
sippers.add(mBluetoothBatterySipper);
+ sippers.add(mIdleBatterySipper);
when(mProvider.isTypeSystem(mSystemBatterySipper))
.thenReturn(true);
doNothing().when(mBatteryUtils).smearScreenBatterySipper(any(), any());