Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b2f363e5 authored by ykhung's avatar ykhung
Browse files

Remove schedule by routine relative tests

Fix: 259866871
Test: make test DEBUG_ROBOLECTRIC=1 ROBOTEST_FILTER="com.android.settings.fuelgauge.batterysaver" RunSettingsRoboTests -j40
Change-Id: Icc402c678c4c4b365047c01c499b17f6d5ec3ada
parent 063a51a7
Loading
Loading
Loading
Loading
+0 −13
Original line number Diff line number Diff line
@@ -80,17 +80,4 @@ public class BatterySaverSchedulePreferenceControllerTest {

        assertThat(mPreference.getSummary()).isEqualTo("Will turn on at 20%");
    }

    @Test
    public void testPreference_percentageRoutine_summaryRoutine() {
        // It doesn't matter what this is set to for routine mode
        Settings.Global.putInt(mContext.getContentResolver(),
                Settings.Global.LOW_POWER_MODE_TRIGGER_LEVEL, TRIGGER_LEVEL);
        Settings.Global.putInt(mContext.getContentResolver(),
                Global.AUTOMATIC_POWER_SAVE_MODE, PowerManager.POWER_SAVE_MODE_TRIGGER_DYNAMIC);

        mController.updateState(mPreference);

        assertThat(mPreference.getSummary()).isEqualTo("Based on your routine");
    }
}
+0 −10
Original line number Diff line number Diff line
@@ -51,16 +51,6 @@ public final class BatterySaverScheduleSettingsTest {
        verifySchedule("key_battery_saver_no_schedule", expectedPercentage);
    }

    @Test
    public void onPause_withRoutineScheduleType_logExpectedData() {
        int expectedPercentage = 0;
        setSchedule(PowerManager.POWER_SAVE_MODE_TRIGGER_DYNAMIC, expectedPercentage);

        mBatterySaverScheduleSettings.onPause();

        verifySchedule("key_battery_saver_routine", expectedPercentage);
    }

    @Test
    public void onPause_withPercentageScheduleType_logExpectedData() {
        int expectedPercentage = 10;