/packages/apps/Settings/tests/robotests/src/com/android/settings/dashboard/ |
D | ProgressiveDisclosureTest.java | 65 private PreferenceScreen mScreen; field in ProgressiveDisclosureTest 74 mScreen = mPreferenceFragment.getPreferenceScreen(); in setUp() 85 when(mScreen.getPreferenceCount()).thenReturn(5); in shouldNotCollapse_lessPreferenceThanLimit() 89 assertThat(mMixin.shouldCollapse(mScreen)).isFalse(); in shouldNotCollapse_lessPreferenceThanLimit() 94 when(mScreen.getPreferenceCount()).thenReturn(5); in shouldNotCollapse_preferenceCountSameAsThreshold() 98 assertThat(mMixin.shouldCollapse(mScreen)).isFalse(); in shouldNotCollapse_preferenceCountSameAsThreshold() 103 when(mScreen.getPreferenceCount()).thenReturn(5); in shouldNotCollapse_whenStartAsExpanded() 109 assertThat(mMixin.shouldCollapse(mScreen)).isFalse(); in shouldNotCollapse_whenStartAsExpanded() 114 when(mScreen.getPreferenceCount()).thenReturn(5); in shouldCollapse_morePreferenceThanLimit() 117 assertThat(mMixin.shouldCollapse(mScreen)).isTrue(); in shouldCollapse_morePreferenceThanLimit() [all …]
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/core/ |
D | DynamicAvailabilityPreferenceControllerTest.java | 51 private @Mock PreferenceScreen mScreen; field in DynamicAvailabilityPreferenceControllerTest 62 when(mScreen.findPreference(PREFERENCE_KEY)).thenReturn(mPreference); in setUp() 63 when(mScreen.getPreferenceCount()).thenReturn(1); in setUp() 64 when(mScreen.getPreference(0)).thenReturn(mPreference); in setUp() 75 controller.displayPreference(mScreen); in testAvailableToUnavailable() 76 verify(mScreen, never()).removePreference(mPreference); in testAvailableToUnavailable() 77 verify(mScreen, never()).addPreference(mPreference); in testAvailableToUnavailable() 81 verify(mScreen, never()).removePreference(mPreference); in testAvailableToUnavailable() 82 verify(mScreen, never()).addPreference(mPreference); in testAvailableToUnavailable() 88 verify(mScreen).removePreference(mPreference); in testAvailableToUnavailable() [all …]
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/development/ |
D | BugReportInPowerPreferenceControllerTest.java | 55 private PreferenceScreen mScreen; field in BugReportInPowerPreferenceControllerTest 73 when(mScreen.findPreference(anyString())).thenReturn(mPreference); in setUp() 81 when(mScreen.getPreferenceCount()).thenReturn(1); in displayPreference_hasDebugRestriction_shouldRemovePreference() 82 when(mScreen.getPreference(0)).thenReturn(mPreference); in displayPreference_hasDebugRestriction_shouldRemovePreference() 84 mController.displayPreference(mScreen); in displayPreference_hasDebugRestriction_shouldRemovePreference() 86 verify(mScreen).removePreference(any(Preference.class)); in displayPreference_hasDebugRestriction_shouldRemovePreference() 93 mController.displayPreference(mScreen); in displayPreference_noDebugRestriction_shouldNotRemovePreference() 95 verify(mScreen, never()).removePreference(any(Preference.class)); in displayPreference_noDebugRestriction_shouldNotRemovePreference() 101 mController.displayPreference(mScreen); in enablePreference_hasDebugRestriction_shouldNotEnable() 112 mController.displayPreference(mScreen); in enablePreference_noDebugRestriction_shouldEnable() [all …]
|
D | VerifyAppsOverUsbPreferenceControllerTest.java | 57 private PreferenceScreen mScreen; field in VerifyAppsOverUsbPreferenceControllerTest 82 when(mScreen.findPreference(anyString())).thenReturn(mPreference); in setUp() 107 mController.displayPreference(mScreen); in updateState_preferenceCheckedWhenSettingIsOn() 117 mController.displayPreference(mScreen); in updateState_preferenceUncheckedWhenSettingIsOff() 127 mController.displayPreference(mScreen); in updateState_preferenceUncheckedWhenNoAdb() 139 mController.displayPreference(mScreen); in updateState_preferenceUncheckedWhenVerifierIsOff() 150 mController.displayPreference(mScreen); in updateState_preferenceUncheckedWhenNoVerifyBroadcastReceivers() 162 mController.displayPreference(mScreen); in updateState_preferenceDisabledWhenRestrictedByAdmin() 172 when(mScreen.getPreferenceCount()).thenReturn(1); in updateState_preferenceRemovedWhenVerifierSettingsVisibleIsOff() 173 when(mScreen.getPreference(anyInt())).thenReturn(mPreference); in updateState_preferenceRemovedWhenVerifierSettingsVisibleIsOff() [all …]
|
D | BugReportPreferenceControllerTest.java | 51 private PreferenceScreen mScreen; field in BugReportPreferenceControllerTest 61 when(mScreen.findPreference(anyString())).thenReturn(mPreference); in setUp() 68 when(mScreen.getPreferenceCount()).thenReturn(1); in displayPreference_hasDebugRestriction_shouldRemovePreference() 69 when(mScreen.getPreference(0)).thenReturn(mPreference); in displayPreference_hasDebugRestriction_shouldRemovePreference() 72 mController.displayPreference(mScreen); in displayPreference_hasDebugRestriction_shouldRemovePreference() 74 verify(mScreen).removePreference(any(Preference.class)); in displayPreference_hasDebugRestriction_shouldRemovePreference() 81 mController.displayPreference(mScreen); in displayPreference_noDebugRestriction_shouldNotRemovePreference() 83 verify(mScreen, never()).removePreference(any(Preference.class)); in displayPreference_noDebugRestriction_shouldNotRemovePreference() 89 mController.displayPreference(mScreen); in enablePreference_hasDebugRestriction_shouldNotEnable() 99 mController.displayPreference(mScreen); in enablePreference_noDebugRestriction_shouldEnable()
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/ |
D | SettingsPreferenceFragmentTest.java | 80 final PreferenceScreen mScreen = spy(new PreferenceScreen(mContext, null)); in removePreference_nested_shouldRemove() local 81 when(mScreen.getPreferenceManager()).thenReturn(mock(PreferenceManager.class)); in removePreference_nested_shouldRemove() 88 mScreen.addPreference(nestedCategory); in removePreference_nested_shouldRemove() 91 assertThat(mFragment.removePreference(mScreen, key)).isTrue(); in removePreference_nested_shouldRemove() 98 final PreferenceScreen mScreen = spy(new PreferenceScreen(mContext, null)); in removePreference_flat_shouldRemove() local 99 when(mScreen.getPreferenceManager()).thenReturn(mock(PreferenceManager.class)); in removePreference_flat_shouldRemove() 104 mScreen.addPreference(preference); in removePreference_flat_shouldRemove() 106 assertThat(mFragment.removePreference(mScreen, key)).isTrue(); in removePreference_flat_shouldRemove() 107 assertThat(mScreen.getPreferenceCount()).isEqualTo(0); in removePreference_flat_shouldRemove() 113 final PreferenceScreen mScreen = spy(new PreferenceScreen(mContext, null)); in removePreference_doNotExist_shouldNotRemove() local [all …]
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/gestures/ |
D | GesturePreferenceControllerTest.java | 55 private PreferenceScreen mScreen; field in GesturePreferenceControllerTest 69 when(mScreen.findPreference(anyString())).thenReturn(mock(VideoPreference.class)); in display_configIsTrue_shouldDisplay() 71 mController.displayPreference(mScreen); in display_configIsTrue_shouldDisplay() 73 verify(mScreen, never()).removePreference(any(Preference.class)); in display_configIsTrue_shouldDisplay() 80 when(mScreen.getPreferenceCount()).thenReturn(1); in display_configIsFalse_shouldNotDisplay() 81 when(mScreen.getPreference(0)).thenReturn(preference); in display_configIsFalse_shouldNotDisplay() 84 mController.displayPreference(mScreen); in display_configIsFalse_shouldNotDisplay() 86 verify(mScreen).removePreference(any(Preference.class)); in display_configIsFalse_shouldNotDisplay() 92 when(mScreen.findPreference(mController.getVideoPrefKey())).thenReturn(videoPreference); in onResume_shouldStartVideoPreferenceWithVideoPauseState() 95 mController.displayPreference(mScreen); in onResume_shouldStartVideoPreferenceWithVideoPauseState() [all …]
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/notification/ |
D | WorkSoundPreferenceControllerTest.java | 64 private PreferenceScreen mScreen; field in WorkSoundPreferenceControllerTest 81 when(mScreen.findPreference(KEY_WORK_CATEGORY)) in setUp() 129 when(mFragment.getPreferenceScreen()).thenReturn(mScreen); in onManagedProfileAdded_shouldDisplayPreferenceCategory() 135 mController.displayPreference(mScreen); in onManagedProfileAdded_shouldDisplayPreferenceCategory() 151 when(mFragment.getPreferenceScreen()).thenReturn(mScreen); in onManagedProfileRemoved_shouldHidePreferenceCategory() 158 mController.displayPreference(mScreen); in onManagedProfileRemoved_shouldHidePreferenceCategory() 178 when(mFragment.getPreferenceScreen()).thenReturn(mScreen); in displayPreference_isAvailable_shouldShowPreferenceCategory() 181 mController.displayPreference(mScreen); in displayPreference_isAvailable_shouldShowPreferenceCategory() 190 when(mFragment.getPreferenceScreen()).thenReturn(mScreen); in displayPreference_notAvailable_shouldHidePreferenceCategory() 192 mController.displayPreference(mScreen); in displayPreference_notAvailable_shouldHidePreferenceCategory() [all …]
|
D | EmergencyTonePreferenceControllerTest.java | 49 private PreferenceScreen mScreen; field in EmergencyTonePreferenceControllerTest 74 when(mScreen.findPreference(mController.getPreferenceKey())).thenReturn(mPreference); in setUp() 75 doReturn(mScreen).when(mSetting).getPreferenceScreen(); in setUp() 94 mController.displayPreference(mScreen); in displayPreference_emergencyToneOff_shouldSelectFirstItem() 103 mController.displayPreference(mScreen); in displayPreference_emergencyToneAlert_shouldSelectSecondItem() 112 mController.displayPreference(mScreen); in displayPreference_emergencyToneVibrate_shouldSelectThirdItem() 119 mController.displayPreference(mScreen); in onPreferenceChanged_firstItemSelected_shouldSetEmergencyToneToOff() 128 mController.displayPreference(mScreen); in onPreferenceChanged_secondItemSelected_shouldSetEmergencyToneToAlert() 137 mController.displayPreference(mScreen); in onPreferenceChanged_thirdItemSelected_shouldSetEmergencyToneToVibrate()
|
D | VibrateWhenRingPreferenceControllerTest.java | 51 private PreferenceScreen mScreen; field in VibrateWhenRingPreferenceControllerTest 67 when(mScreen.findPreference(mController.getPreferenceKey())) in display_voiceCapable_shouldDisplay() 70 mController.displayPreference(mScreen); in display_voiceCapable_shouldDisplay() 72 verify(mScreen, never()).removePreference(any(Preference.class)); in display_voiceCapable_shouldDisplay() 79 when(mScreen.getPreferenceCount()).thenReturn(1); in display_notVoiceCapable_shouldNotDisplay() 80 when(mScreen.getPreference(0)).thenReturn(preference); in display_notVoiceCapable_shouldNotDisplay() 83 mController.displayPreference(mScreen); in display_notVoiceCapable_shouldNotDisplay() 85 verify(mScreen).removePreference(any(Preference.class)); in display_notVoiceCapable_shouldNotDisplay()
|
D | ScreenLockSoundPreferenceControllerTest.java | 46 private PreferenceScreen mScreen; field in ScreenLockSoundPreferenceControllerTest 66 when(mScreen.findPreference(mController.getPreferenceKey())).thenReturn(mPreference); in setUp() 67 doReturn(mScreen).when(mSetting).getPreferenceScreen(); in setUp() 79 mController.displayPreference(mScreen); in displayPreference_lockScreenSoundEnabled_shouldCheckedPreference() 88 mController.displayPreference(mScreen); in displayPreference_lockScreenSoundDisabled_shouldUncheckedPreference() 95 mController.displayPreference(mScreen); in onPreferenceChanged_preferenceChecked_shouldEnabledLockScreenSound() 105 mController.displayPreference(mScreen); in onPreferenceChanged_preferenceUnchecked_shouldDisabledLockScreenSound()
|
D | ChargingSoundPreferenceControllerTest.java | 46 private PreferenceScreen mScreen; field in ChargingSoundPreferenceControllerTest 66 when(mScreen.findPreference(mController.getPreferenceKey())).thenReturn(mPreference); in setUp() 67 doReturn(mScreen).when(mSetting).getPreferenceScreen(); in setUp() 79 mController.displayPreference(mScreen); in displayPreference_chargingSoundEnabled_shouldCheckedPreference() 88 mController.displayPreference(mScreen); in displayPreference_chargingSoundDisabled_shouldUncheckedPreference() 95 mController.displayPreference(mScreen); in onPreferenceChanged_preferenceChecked_shouldEnabledChargingSound() 105 mController.displayPreference(mScreen); in onPreferenceChanged_preferenceUnchecked_shouldDisabledChargingSound()
|
D | TouchSoundPreferenceControllerTest.java | 50 private PreferenceScreen mScreen; field in TouchSoundPreferenceControllerTest 71 when(mScreen.findPreference(mController.getPreferenceKey())).thenReturn(mPreference); in setUp() 72 doReturn(mScreen).when(mSetting).getPreferenceScreen(); in setUp() 84 mController.displayPreference(mScreen); in displayPreference_soundEffectEnabled_shouldCheckedPreference() 93 mController.displayPreference(mScreen); in displayPreference_soundEffectDisabled_shouldUncheckedPreference() 100 mController.displayPreference(mScreen); in onPreferenceChanged_preferenceChecked_shouldEnabledSoundEffect() 109 mController.displayPreference(mScreen); in onPreferenceChanged_preferenceUnchecked_shouldDisabledSoundEffect()
|
D | PulseNotificationPreferenceControllerTest.java | 51 private PreferenceScreen mScreen; field in PulseNotificationPreferenceControllerTest 66 mController.displayPreference(mScreen); in display_configIsTrue_shouldDisplay() 68 verify(mScreen, never()).removePreference(any(Preference.class)); in display_configIsTrue_shouldDisplay() 77 when(mScreen.getPreferenceCount()).thenReturn(1); in display_configIsFalse_shouldNotDisplay() 78 when(mScreen.getPreference(0)).thenReturn(preference); in display_configIsFalse_shouldNotDisplay() 81 mController.displayPreference(mScreen); in display_configIsFalse_shouldNotDisplay() 83 verify(mScreen).removePreference(any(Preference.class)); in display_configIsFalse_shouldNotDisplay()
|
D | DialPadTonePreferenceControllerTest.java | 49 private PreferenceScreen mScreen; field in DialPadTonePreferenceControllerTest 72 when(mScreen.findPreference(mController.getPreferenceKey())).thenReturn(mPreference); in setUp() 73 doReturn(mScreen).when(mSetting).getPreferenceScreen(); in setUp() 92 mController.displayPreference(mScreen); in displayPreference_dialToneEnabled_shouldCheckedPreference() 101 mController.displayPreference(mScreen); in displayPreference_dialToneDisabled_shouldUncheckedPreference() 108 mController.displayPreference(mScreen); in onPreferenceChanged_preferenceChecked_shouldEnabledDialTone() 117 mController.displayPreference(mScreen); in onPreferenceChanged_preferenceUnchecked_shouldDisabledDialTone()
|
D | VibrateOnTouchPreferenceControllerTest.java | 48 private PreferenceScreen mScreen; field in VibrateOnTouchPreferenceControllerTest 73 when(mScreen.findPreference(mController.getPreferenceKey())).thenReturn(mPreference); in setUp() 74 doReturn(mScreen).when(mSetting).getPreferenceScreen(); in setUp() 94 mController.displayPreference(mScreen); in displayPreference_hapticEnabled_shouldCheckedPreference() 103 mController.displayPreference(mScreen); in displayPreference_hapticDisabled_shouldUncheckedPreference() 110 mController.displayPreference(mScreen); in onPreferenceChanged_preferenceChecked_shouldEnabledHaptic() 119 mController.displayPreference(mScreen); in onPreferenceChanged_preferenceUnchecked_shouldDisabledHaptic()
|
D | DockingSoundPreferenceControllerTest.java | 47 private PreferenceScreen mScreen; field in DockingSoundPreferenceControllerTest 69 when(mScreen.findPreference(mController.getPreferenceKey())).thenReturn(mPreference); in setUp() 70 doReturn(mScreen).when(mSetting).getPreferenceScreen(); in setUp() 93 mController.displayPreference(mScreen); in displayPreference_dockingSoundEnabled_shouldCheckedPreference() 102 mController.displayPreference(mScreen); in displayPreference_dockingSoundDisabled_shouldUncheckedPreference() 109 mController.displayPreference(mScreen); in onPreferenceChanged_preferenceChecked_shouldEnabledDockingSound() 118 mController.displayPreference(mScreen); in onPreferenceChanged_preferenceUnchecked_shouldDisabledDockingSound()
|
D | DockAudioMediaPreferenceControllerTest.java | 48 private PreferenceScreen mScreen; field in DockAudioMediaPreferenceControllerTest 72 when(mScreen.findPreference(mController.getPreferenceKey())).thenReturn(mPreference); in setUp() 73 doReturn(mScreen).when(mSetting).getPreferenceScreen(); in setUp() 96 mController.displayPreference(mScreen); in displayPreference_dockAudioDisabled_shouldSelectFirstItem() 105 mController.displayPreference(mScreen); in displayPreference_dockAudioEnabled_shouldSelectSecondItem() 112 mController.displayPreference(mScreen); in onPreferenceChanged_firstItemSelected_shouldDisableDockAudio() 122 mController.displayPreference(mScreen); in onPreferenceChanged_secondItemSelected_shouldEnableDockAudio()
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/accounts/ |
D | AutoSyncPersonalDataPreferenceControllerTest.java | 49 private PreferenceScreen mScreen; field in AutoSyncPersonalDataPreferenceControllerTest 67 when(mScreen.getPreferenceCount()).thenReturn(1); in setUp() 68 when(mScreen.getPreference(0)).thenReturn(mPreference); in setUp() 76 mController.displayPreference(mScreen); in displayPref_managedProfile_shouldNotDisplay() 78 verify(mScreen).removePreference(any(Preference.class)); in displayPref_managedProfile_shouldNotDisplay() 86 mController.displayPreference(mScreen); in displayPref_linkedUser_shouldNotDisplay() 88 verify(mScreen).removePreference(any(Preference.class)); in displayPref_linkedUser_shouldNotDisplay() 99 mController.displayPreference(mScreen); in displayPref_oneProfile_shouldNotDisplay() 101 verify(mScreen).removePreference(any(Preference.class)); in displayPref_oneProfile_shouldNotDisplay() 113 mController.displayPreference(mScreen); in displayPref_prefAvaiable_shouldDisplay() [all …]
|
D | AutoSyncDataPreferenceControllerTest.java | 53 private PreferenceScreen mScreen; field in AutoSyncDataPreferenceControllerTest 74 when(mScreen.getPreferenceCount()).thenReturn(1); in setUp() 75 when(mScreen.getPreference(0)).thenReturn(mPreference); in setUp() 83 mController.displayPreference(mScreen); in displayPref_managedProfile_shouldNotDisplay() 85 verify(mScreen).removePreference(any(Preference.class)); in displayPref_managedProfile_shouldNotDisplay() 93 mController.displayPreference(mScreen); in displayPref_linkedUser_shouldDisplay() 95 verify(mScreen, never()).removePreference(any(Preference.class)); in displayPref_linkedUser_shouldDisplay() 106 mController.displayPreference(mScreen); in displayPref_oneProfile_shouldDisplay() 108 verify(mScreen, never()).removePreference(any(Preference.class)); in displayPref_oneProfile_shouldDisplay() 120 mController.displayPreference(mScreen); in displayPref_moreThanOneProfile_shouldNotDisplay() [all …]
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/wifi/tether/ |
D | WifiTetherPreferenceControllerTest.java | 78 private PreferenceScreen mScreen; field in WifiTetherPreferenceControllerTest 93 when(mScreen.findPreference(anyString())).thenReturn(mPreference); in setUp() 121 mController.displayPreference(mScreen); in startAndStop_shouldRegisterUnregisterReceiver() 136 when(mScreen.findPreference(anyString())).thenReturn(pref); in start_wifiApOff_shouldSetInitialStateToOff() 138 mController.displayPreference(mScreen); in start_wifiApOff_shouldSetInitialStateToOff() 151 when(mScreen.findPreference(anyString())).thenReturn(pref); in start_wifiApOn_shouldSetInitialStateToOn() 153 mController.displayPreference(mScreen); in start_wifiApOn_shouldSetInitialStateToOn() 163 mController.displayPreference(mScreen); in testReceiver_apStateChangedToDisabled_shouldUpdatePreferenceSummary() 171 mController.displayPreference(mScreen); in testReceiver_apStateChangedToDisabling_shouldUpdatePreferenceSummary() 179 mController.displayPreference(mScreen); in testReceiver_apStateChangedToEnabling_shouldUpdatePreferenceSummary() [all …]
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/security/ |
D | OwnerInfoPreferenceControllerTest.java | 59 private PreferenceScreen mScreen; field in OwnerInfoPreferenceControllerTest 79 when(mFragment.getPreferenceScreen()).thenReturn(mScreen); in setUp() 85 when(mScreen.findPreference(mController.getPreferenceKey())).thenReturn(mPreference); in setUp() 113 mController.displayPreference(mScreen); in updateSummary_deviceOwnerInfoEnabled_shouldSetDeviceOwnerInfoSummary() 126 mController.displayPreference(mScreen); in updateSummary_ownerInfoEnabled_shouldSetOwnerInfoSummary() 137 mController.displayPreference(mScreen); in updateSummary_ownerInfoDisabled_shouldSetDefaultSummary() 149 mController.displayPreference(mScreen); in updateEnableState_deviceOwnerInfoEnabled_shouldSetDisabledByAdmin() 160 mController.displayPreference(mScreen); in updateEnableState_lockScreenDisabled_shouldDisablePreference() 171 mController.displayPreference(mScreen); in updateEnableState_lockScreenEnabled_shouldEnablePreference() 183 when(mScreen.findPreference(mController.getPreferenceKey())).thenReturn(preference); in performClick_shouldLaunchOwnerInfoSettings() [all …]
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/deviceinfo/ |
D | SystemUpdatePreferenceControllerTest.java | 55 private PreferenceScreen mScreen; field in SystemUpdatePreferenceControllerTest 90 when(mScreen.getPreferenceCount()).thenReturn(1); in displayPrefs_nothingAvailable_shouldNotDisplay() 91 when(mScreen.getPreference(0)).thenReturn(preference); in displayPrefs_nothingAvailable_shouldNotDisplay() 94 mController.displayPreference(mScreen); in displayPrefs_nothingAvailable_shouldNotDisplay() 96 verify(mScreen).removePreference(any(Preference.class)); in displayPrefs_nothingAvailable_shouldNotDisplay() 114 when(mScreen.getPreferenceCount()).thenReturn(1); in displayPrefs_oneAvailable_shouldDisplayOne() 115 when(mScreen.getPreference(0)).thenReturn(preference); in displayPrefs_oneAvailable_shouldDisplayOne() 122 mController.displayPreference(mScreen); in displayPrefs_oneAvailable_shouldDisplayOne() 124 verify(mScreen).removePreference(any(Preference.class)); in displayPrefs_oneAvailable_shouldDisplayOne()
|
D | SerialNumberPreferenceControllerTest.java | 49 private PreferenceScreen mScreen; field in SerialNumberPreferenceControllerTest 75 when(mScreen.getPreferenceCount()).thenReturn(1); in testDisplay_noSerial_shouldHidePreference() 76 when(mScreen.getPreference(0)).thenReturn(preference); in testDisplay_noSerial_shouldHidePreference() 80 mController.displayPreference(mScreen); in testDisplay_noSerial_shouldHidePreference() 82 verify(mScreen).removePreference(any(Preference.class)); in testDisplay_noSerial_shouldHidePreference() 89 when(mScreen.findPreference(anyString())).thenReturn(preference); in testDisplay_hasSerial_shouldSummary() 92 mController.displayPreference(mScreen); in testDisplay_hasSerial_shouldSummary() 94 verify(mScreen, never()).removePreference(any(Preference.class)); in testDisplay_hasSerial_shouldSummary()
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/location/ |
D | AppLocationPermissionPreferenceControllerTest.java | 32 private PreferenceScreen mScreen; field in AppLocationPermissionPreferenceControllerTest 42 when(mScreen.findPreference(anyString())).thenReturn(mPreference); in setUp() 51 when(mScreen.getPreferenceCount()).thenReturn(1); in displayPreference_shouldRemovePreference() 52 when(mScreen.getPreference(0)).thenReturn(mPreference); in displayPreference_shouldRemovePreference() 55 mController.displayPreference(mScreen); in displayPreference_shouldRemovePreference() 57 verify(mScreen).removePreference(any(Preference.class)); in displayPreference_shouldRemovePreference() 65 mController.displayPreference(mScreen); in displayPreference_shouldNotRemovePreference() 67 verify(mScreen, never()).removePreference(any(Preference.class)); in displayPreference_shouldNotRemovePreference()
|