Home
last modified time | relevance | path

Searched refs:mockInfo (Results 1 – 6 of 6) sorted by relevance

/packages/apps/Car/Settings/tests/unit/src/com/android/car/settings/inputmethod/
DEnabledKeyboardPreferenceControllerTest.java261 InputMethodInfo mockInfo = createMockInputMethodInfo(packageManager, packageName, in createMockInputMethodInfoWithSubtypes() local
267 return mockInfo; in createMockInputMethodInfoWithSubtypes()
272 InputMethodInfo mockInfo = mock(InputMethodInfo.class); in createMockInputMethodInfo() local
273 when(mockInfo.getPackageName()).thenReturn(packageName); in createMockInputMethodInfo()
274 when(mockInfo.getId()).thenReturn(PLACEHOLDER_ID); in createMockInputMethodInfo()
275 when(mockInfo.loadLabel(packageManager)).thenReturn(PLACEHOLDER_LABEL); in createMockInputMethodInfo()
276 when(mockInfo.getServiceInfo()).thenReturn(new ServiceInfo()); in createMockInputMethodInfo()
277 when(mockInfo.getSettingsActivity()).thenReturn(settingsName); in createMockInputMethodInfo()
278 return mockInfo; in createMockInputMethodInfo()
DInputMethodUtilTest.java342 InputMethodInfo mockInfo = createMockInputMethodInfo(packageManager, packageName); in createMockInputMethodInfoWithSubtypes() local
345 eq(mockInfo), anyBoolean())).thenReturn(subtypes); in createMockInputMethodInfoWithSubtypes()
346 return mockInfo; in createMockInputMethodInfoWithSubtypes()
351 InputMethodInfo mockInfo = mock(InputMethodInfo.class); in createMockInputMethodInfo() local
352 when(mockInfo.getPackageName()).thenReturn(packageName); in createMockInputMethodInfo()
353 when(mockInfo.loadLabel(packageManager)).thenReturn(PLACEHOLDER_LABEL); in createMockInputMethodInfo()
354 when(mockInfo.getServiceInfo()).thenReturn(new ServiceInfo()); in createMockInputMethodInfo()
355 when(mockInfo.getSettingsActivity()).thenReturn(PLACEHOLDER_SETTINGS_ACTIVITY); in createMockInputMethodInfo()
356 return mockInfo; in createMockInputMethodInfo()
DKeyboardManagementPreferenceControllerTest.java1126 InputMethodInfo mockInfo = mock(InputMethodInfo.class); in createMockInputMethodInfo() local
1127 when(mockInfo.getPackageName()).thenReturn(packageName); in createMockInputMethodInfo()
1128 when(mockInfo.loadLabel(packageManager)).thenReturn(PLACEHOLDER_LABEL); in createMockInputMethodInfo()
1129 when(mockInfo.getServiceInfo()).thenReturn(mockServiceInfo); in createMockInputMethodInfo()
1130 when(mockInfo.getSettingsActivity()).thenReturn(PLACEHOLDER_SETTINGS_ACTIVITY); in createMockInputMethodInfo()
1131 when(mockInfo.getId()).thenReturn(id); in createMockInputMethodInfo()
1132 when(mockInfo.isDefault(context)).thenReturn(isDefaultable); in createMockInputMethodInfo()
1136 return mockInfo; in createMockInputMethodInfo()
/packages/apps/Settings/tests/robotests/src/com/android/settings/accessibility/
DRestrictedPreferenceHelperTest.java169 private void setMockAccessibilityShortcutInfo(AccessibilityShortcutInfo mockInfo) { in setMockAccessibilityShortcutInfo() argument
172 when(mockInfo.getActivityInfo()).thenReturn(activityInfo); in setMockAccessibilityShortcutInfo()
174 when(mockInfo.loadSummary(any())).thenReturn(DEFAULT_SUMMARY); in setMockAccessibilityShortcutInfo()
175 when(mockInfo.loadDescription(any())).thenReturn(DEFAULT_DESCRIPTION); in setMockAccessibilityShortcutInfo()
176 when(mockInfo.getComponentName()).thenReturn(COMPONENT_NAME); in setMockAccessibilityShortcutInfo()
DAccessibilitySettingsTest.java448 private void setMockAccessibilityShortcutInfo(AccessibilityShortcutInfo mockInfo) { in setMockAccessibilityShortcutInfo() argument
451 when(mockInfo.getActivityInfo()).thenReturn(activityInfo); in setMockAccessibilityShortcutInfo()
453 when(mockInfo.loadSummary(any())).thenReturn(DEFAULT_SUMMARY); in setMockAccessibilityShortcutInfo()
454 when(mockInfo.loadDescription(any())).thenReturn(DEFAULT_DESCRIPTION); in setMockAccessibilityShortcutInfo()
455 when(mockInfo.getComponentName()).thenReturn(COMPONENT_NAME); in setMockAccessibilityShortcutInfo()
/packages/services/Car/tests/carservice_unit_test/src/com/android/car/audio/
DCarAudioVolumeGroupTest.java573 AudioDeviceInfo mockInfo = Mockito.mock(AudioDeviceInfo.class); in audioDevicesAdded_whileInactive() local
580 boolean updated = carVolumeGroup.audioDevicesAdded(List.of(mockInfo)); in audioDevicesAdded_whileInactive()
584 expectWithMessage("Devices added while inactive").that(devices).containsExactly(mockInfo); in audioDevicesAdded_whileInactive()
590 AudioDeviceInfo mockInfo = Mockito.mock(AudioDeviceInfo.class); in audioDevicesAdded_whileActive() local
596 boolean updated = carVolumeGroup.audioDevicesAdded(List.of(mockInfo)); in audioDevicesAdded_whileActive()
618 AudioDeviceInfo mockInfo = Mockito.mock(AudioDeviceInfo.class); in audioDevicesRemoved_whileActive() local
624 boolean updated = carVolumeGroup.audioDevicesRemoved(List.of(mockInfo)); in audioDevicesRemoved_whileActive()
628 expectWithMessage("Devices removed").that(devices).containsExactly(mockInfo); in audioDevicesRemoved_whileActive()
633 AudioDeviceInfo mockInfo = Mockito.mock(AudioDeviceInfo.class); in audioDevicesRemoved_whileInactive() local
639 boolean updated = carVolumeGroup.audioDevicesRemoved(List.of(mockInfo)); in audioDevicesRemoved_whileInactive()
[all …]