Home | History | Annotate | Download | only in bluetooth

Lines Matching refs:when

27 import static org.mockito.Mockito.when;
66 doNothing().when(dialogActivity).dismiss();
72 when(controller.getDialogType()).thenReturn(BluetoothPairingController.USER_ENTRY_DIALOG);
75 when(controller.getDeviceVariantMessageId())
77 when(controller.getDeviceVariantMessageHintId())
91 when(controller.getDialogType()).thenReturn(BluetoothPairingController.USER_ENTRY_DIALOG);
94 when(controller.getDeviceVariantMessageId())
96 when(controller.getDeviceVariantMessageHintId())
100 when(controller.isPasskeyValid(any())).thenReturn(true);
105 // test that the positive button is enabled when passkey is valid
115 when(controller.getDialogType()).thenReturn(BluetoothPairingController.CONFIRMATION_DIALOG);
128 when(controller.getDialogType()).thenReturn(BluetoothPairingController.USER_ENTRY_DIALOG);
131 when(controller.getDeviceVariantMessageId())
133 when(controller.getDeviceVariantMessageHintId())
138 doReturn(imm).when(context).getSystemService(Context.INPUT_METHOD_SERVICE);
142 when(frag.getContext()).thenReturn(context);
150 // check that showSoftInput was called to make input method appear when the dialog was shown
160 when(controller.getDialogType())
164 when(controller.isDisplayPairingKeyVariant()).thenReturn(true);
165 when(controller.hasPairingContent()).thenReturn(true);
166 when(controller.getPairingContent()).thenReturn(FILLER);
196 when(controller.getDialogType()).thenReturn(BluetoothPairingController.CONFIRMATION_DIALOG);
199 doNothing().when(controller).onDialogPositiveClick(any());
212 when(controller.getDialogType()).thenReturn(BluetoothPairingController.CONFIRMATION_DIALOG);
215 doNothing().when(controller).onDialogNegativeClick(any());
250 when(controller.getDialogType()).thenReturn(BluetoothPairingController.USER_ENTRY_DIALOG);
253 when(controller.getDeviceVariantMessageId())
255 when(controller.getDeviceVariantMessageHintId())
259 when(controller.isPasskeyValid(any())).thenReturn(false);
264 // test that the positive button is enabled when passkey is valid
274 when(controller.getDialogType()).thenReturn(BluetoothPairingController.CONFIRMATION_DIALOG);
277 when(controller.getDeviceName()).thenReturn(FAKE_DEVICE_NAME);
278 when(controller.isProfileReady()).thenReturn(false);
292 when(controller.getDialogType()).thenReturn(BluetoothPairingController.CONFIRMATION_DIALOG);
295 when(controller.getDeviceName()).thenReturn(FAKE_DEVICE_NAME);
296 when(controller.isProfileReady()).thenReturn(true);
310 when(controller.getDialogType()).thenReturn(BluetoothPairingController.USER_ENTRY_DIALOG);
313 when(controller.getDeviceVariantMessageId()).thenReturn(R.string.cancel);
314 when(controller.getDeviceVariantMessageHintId())
329 when(controller.getDialogType()).thenReturn(BluetoothPairingController.USER_ENTRY_DIALOG);
332 when(controller.getDeviceVariantMessageHintId()).thenReturn(R.string.cancel);
333 when(controller.getDeviceVariantMessageId())
348 when(controller.getDialogType()).thenReturn(BluetoothPairingController.USER_ENTRY_DIALOG);
350 // Set the id's to what is returned when it is not provided
351 when(controller.getDeviceVariantMessageHintId())
353 when(controller.getDeviceVariantMessageId())
377 when(controller.getDialogType()).thenReturn(BluetoothPairingController.CONFIRMATION_DIALOG);
380 doNothing().when(controller).onDialogPositiveClick(any());
395 when(controller.getDialogType()).thenReturn(BluetoothPairingController.CONFIRMATION_DIALOG);
398 doNothing().when(controller).onDialogNegativeClick(any());
429 when(controller.getDialogType()).thenReturn(BluetoothPairingController.USER_ENTRY_DIALOG);
430 when(controller.getDeviceVariantMessageHintId())
432 when(controller.getDeviceVariantMessageId())
436 when(fragment.getPairingViewText()).thenReturn(existingText);