Searched refs:mBatteryTipPreferenceController (Results 1 – 3 of 3) sorted by relevance
65 private BatteryTipPreferenceController mBatteryTipPreferenceController; field in BatteryTipPreferenceControllerTest78 mBatteryTipPreferenceController = buildBatteryTipPreferenceController(); in setUp()79 mBatteryTipPreferenceController.mCardPreference = mCardPreference; in setUp()80 mBatteryTipPreferenceController.mPrefContext = mContext; in setUp()85 mBatteryTipPreferenceController.displayPreference(mPreferenceScreen); in displayPreference_isInvisible()92 mBatteryTipPreferenceController.updateBatteryTips(mNewBatteryTips); in updateBatteryTips_tipsStateInvisible_isInvisible()99 assertThat(mBatteryTipPreferenceController.getCurrentBatteryTip()).isNull(); in getCurrentBatteryTip_noTips_isNull()104 mBatteryTipPreferenceController.updateBatteryTips(mNewBatteryTips); in getCurrentBatteryTip_tipsInvisible_isNull()105 assertThat(mBatteryTipPreferenceController.getCurrentBatteryTip()).isNull(); in getCurrentBatteryTip_tipsInvisible_isNull()112 mBatteryTipPreferenceController.saveInstanceState(bundle); in restoreFromNull_shouldNotCrash()[all …]
69 @VisibleForTesting BatteryTipPreferenceController mBatteryTipPreferenceController; field in PowerUsageSummary96 mBatteryTipPreferenceController.getCurrentBatteryTip(), batteryInfo);116 mBatteryTipPreferenceController.updateBatteryTips(data);118 mBatteryTipPreferenceController.getCurrentBatteryTip(), mBatteryInfo);132 mBatteryTipPreferenceController = use(BatteryTipPreferenceController.class); in onAttach()133 mBatteryTipPreferenceController.setActivity(activity); in onAttach()134 mBatteryTipPreferenceController.setFragment(this); in onAttach()135 mBatteryTipPreferenceController.setBatteryTipListener(this::onBatteryTipHandled); in onAttach()154 mBatteryTipPreferenceController.restoreInstanceState(icicle); in onCreate()248 mNeedUpdateBatteryTip = icicle == null || mBatteryTipPreferenceController.needUpdate(); in updateBatteryTipFlag()[all …]
212 mFragment.mBatteryTipPreferenceController = mock(BatteryTipPreferenceController.class); in refreshUi_deviceRotate_doNotUpdateBatteryTip()213 when(mFragment.mBatteryTipPreferenceController.needUpdate()).thenReturn(false); in refreshUi_deviceRotate_doNotUpdateBatteryTip()225 mFragment.mBatteryTipPreferenceController = mock(BatteryTipPreferenceController.class); in refreshUi_batteryLevelChanged_doNotUpdateBatteryTip()226 when(mFragment.mBatteryTipPreferenceController.needUpdate()).thenReturn(true); in refreshUi_batteryLevelChanged_doNotUpdateBatteryTip()238 mFragment.mBatteryTipPreferenceController = mock(BatteryTipPreferenceController.class); in refreshUi_tipNeedUpdate_updateBatteryTip()239 when(mFragment.mBatteryTipPreferenceController.needUpdate()).thenReturn(true); in refreshUi_tipNeedUpdate_updateBatteryTip()