Searched refs:mMockBackend (Results 1 – 1 of 1) sorted by relevance
78 @Mock private PowerAllowlistBackend mMockBackend; field in BatteryOptimizeUtilsTest96 mBatteryOptimizeUtils.mPowerAllowListBackend = mMockBackend; in setUp()105 when(mMockBackend.isAllowlisted(anyString(), anyInt())).thenReturn(false); in testGetAppOptimizationMode_returnRestricted()114 when(mMockBackend.isAllowlisted(anyString(), anyInt())).thenReturn(true); in testGetAppOptimizationMode_returnUnrestricted()123 when(mMockBackend.isAllowlisted(anyString(), anyInt())).thenReturn(false); in testGetAppOptimizationMode_returnOptimized()132 when(mMockBackend.isAllowlisted(anyString(), anyInt())).thenReturn(true); in testIsSystemOrDefaultApp_isSystemOrDefaultApp_returnTrue()133 when(mMockBackend.isDefaultActiveApp(anyString(), anyInt())).thenReturn(true); in testIsSystemOrDefaultApp_isSystemOrDefaultApp_returnTrue()159 when(mMockBackend.isAllowlisted(anyString(), anyInt())).thenReturn(true); in testSetAppUsageState_Restricted_verifyAction()173 when(mMockBackend.isAllowlisted(anyString(), anyInt())).thenReturn(false); in testSetAppUsageState_Unrestricted_verifyAction()187 when(mMockBackend.isAllowlisted(anyString(), anyInt())).thenReturn(true); in testSetAppUsageState_Optimized_verifyAction()[all …]