/packages/apps/Settings/tests/robotests/src/com/android/settings/bluetooth/ |
D | AdvancedBluetoothDetailsHeaderControllerTest.java | 67 private BluetoothDevice mBluetoothDevice; field in AdvancedBluetoothDetailsHeaderControllerTest 85 when(mCachedDevice.getDevice()).thenReturn(mBluetoothDevice); in setUp() 91 when(mCachedDevice.getDevice()).thenReturn(mBluetoothDevice); in setUp() 109 when(mBluetoothDevice.getMetadata( in refresh_connected_updateCorrectInfo() 112 when(mBluetoothDevice.getMetadata( in refresh_connected_updateCorrectInfo() 115 when(mBluetoothDevice.getMetadata( in refresh_connected_updateCorrectInfo() 150 when(mBluetoothDevice.getMetadata(BluetoothDevice.METADATA_IS_UNTETHERED_HEADSET)) in getAvailabilityStatus_untetheredHeadsetWithConfigOn_returnAvailable() 161 when(mBluetoothDevice.getMetadata(BluetoothDevice.METADATA_IS_UNTETHERED_HEADSET)) in getAvailabilityStatus_untetheredHeadsetWithConfigOff_returnUnavailable() 172 when(mBluetoothDevice.getMetadata(BluetoothDevice.METADATA_IS_UNTETHERED_HEADSET)) in getAvailabilityStatus_notUntetheredHeadsetWithConfigOn_returnUnavailable() 183 when(mBluetoothDevice.getMetadata(BluetoothDevice.METADATA_IS_UNTETHERED_HEADSET)) in getAvailabilityStatus_notUntetheredHeadsetWithConfigOff_returnUnavailable() [all …]
|
D | BluetoothPairingControllerTest.java | 45 private BluetoothDevice mBluetoothDevice; field in BluetoothPairingControllerTest 55 intent.putExtra(BluetoothDevice.EXTRA_DEVICE, mBluetoothDevice); in setUp() 66 verify(mBluetoothDevice).setPhonebookAccessPermission(BluetoothDevice.ACCESS_ALLOWED); in onDialogPositiveClick_confirmationDialog_setPBAP() 71 when(mBluetoothDevice.getPhonebookAccessPermission()).thenReturn( in onSetContactSharingState_permissionAllowed_setPBAPAllowed() 76 verify(mBluetoothDevice).setPhonebookAccessPermission(BluetoothDevice.ACCESS_ALLOWED); in onSetContactSharingState_permissionAllowed_setPBAPAllowed() 81 when(mBluetoothDevice.getPhonebookAccessPermission()).thenReturn( in onSetContactSharingState_permissionUnknown_audioVideoHandsfree_setPBAPAllowed() 83 when(mBluetoothDevice.getBluetoothClass()).thenReturn(mBluetoothClass); in onSetContactSharingState_permissionUnknown_audioVideoHandsfree_setPBAPAllowed() 87 verify(mBluetoothDevice).setPhonebookAccessPermission(BluetoothDevice.ACCESS_ALLOWED); in onSetContactSharingState_permissionUnknown_audioVideoHandsfree_setPBAPAllowed() 92 when(mBluetoothDevice.getPhonebookAccessPermission()).thenReturn( in onSetContactSharingState_permissionRejected_setPBAPRejected() 94 when(mBluetoothDevice.getBluetoothClass()).thenReturn(mBluetoothClass); in onSetContactSharingState_permissionRejected_setPBAPRejected() [all …]
|
D | BluetoothDeviceUpdaterTest.java | 71 private BluetoothDevice mBluetoothDevice; field in BluetoothDeviceUpdaterTest 95 when(mCachedBluetoothDevice.getDevice()).thenReturn(mBluetoothDevice); in setUp() 116 mBluetoothDeviceUpdater.mPreferenceMap.put(mBluetoothDevice, mPreference); in testAddPreference_deviceExist_doNothing() 127 final Preference preference = mBluetoothDeviceUpdater.mPreferenceMap.get(mBluetoothDevice); in testAddPreference_deviceNotExist_addPreference() 134 mBluetoothDeviceUpdater.mPreferenceMap.put(mBluetoothDevice, mPreference); in testRemovePreference_deviceExist_removePreference() 139 assertThat(mBluetoothDeviceUpdater.mPreferenceMap.containsKey(mBluetoothDevice)).isFalse(); in testRemovePreference_deviceExist_removePreference() 144 mBluetoothDeviceUpdater.mPreferenceMap.put(mBluetoothDevice, mPreference); in testOnDeviceDeleted_deviceExists_removePreference() 149 assertThat(mBluetoothDeviceUpdater.mPreferenceMap.containsKey(mBluetoothDevice)).isFalse(); in testOnDeviceDeleted_deviceExists_removePreference() 187 doReturn(BluetoothDevice.BOND_BONDED).when(mBluetoothDevice).getBondState(); in isDeviceConnected_deviceConnected() 188 doReturn(true).when(mBluetoothDevice).isConnected(); in isDeviceConnected_deviceConnected() [all …]
|
D | SavedBluetoothDeviceUpdaterTest.java | 56 private BluetoothDevice mBluetoothDevice; field in SavedBluetoothDeviceUpdaterTest 68 when(mCachedBluetoothDevice.getDevice()).thenReturn(mBluetoothDevice); in setUp() 70 when(mBluetoothDevice.getBondState()).thenReturn(BluetoothDevice.BOND_BONDED); in setUp() 82 doReturn(BluetoothDevice.BOND_BONDED).when(mBluetoothDevice).getBondState(); in update_filterMatch_addPreference() 83 doReturn(false).when(mBluetoothDevice).isConnected(); in update_filterMatch_addPreference() 92 doReturn(BluetoothDevice.BOND_NONE).when(mBluetoothDevice).getBondState(); in update_filterNotMatch_removePreference() 93 doReturn(true).when(mBluetoothDevice).isConnected(); in update_filterNotMatch_removePreference() 102 when(mBluetoothDevice.isConnected()).thenReturn(true); in onProfileConnectionStateChanged_deviceConnected_removePreference() 112 when(mBluetoothDevice.isConnected()).thenReturn(false); in onProfileConnectionStateChanged_deviceDisconnected_addPreference()
|
D | ForgetDeviceDialogFragmentTest.java | 61 private BluetoothDevice mBluetoothDevice; field in ForgetDeviceDialogFragmentTest 76 when(mCachedDevice.getDevice()).thenReturn(mBluetoothDevice); in setUp() 103 when(mBluetoothDevice.getMetadata(BluetoothDevice.METADATA_IS_UNTETHERED_HEADSET)) in createDialog_untetheredDevice_showUntetheredMessage() 117 when(mBluetoothDevice.getMetadata(BluetoothDevice.METADATA_IS_UNTETHERED_HEADSET)) in createDialog_normalDevice_showNormalMessage()
|
D | BluetoothDetailsHeaderControllerTest.java | 62 private BluetoothDevice mBluetoothDevice; field in BluetoothDetailsHeaderControllerTest 78 when(mCachedDevice.getDevice()).thenReturn(mBluetoothDevice); in setUp() 132 when(mBluetoothDevice.getMetadata( in isAvailable_untetheredHeadsetWithConfigOn_returnFalse() 143 when(mBluetoothDevice.getMetadata( in isAvailable_untetheredHeadsetWithConfigOff_returnTrue()
|
D | BluetoothFeatureProviderImplTest.java | 39 private BluetoothDevice mBluetoothDevice; field in BluetoothFeatureProviderImplTest 51 when(mBluetoothDevice.getMetadata( in getBluetoothDeviceSettingsUri_containCorrectMacAddress() 54 final Uri uri = mBluetoothFeatureProvider.getBluetoothDeviceSettingsUri(mBluetoothDevice); in getBluetoothDeviceSettingsUri_containCorrectMacAddress()
|
D | BluetoothPairingDetailTest.java | 75 private BluetoothDevice mBluetoothDevice; field in BluetoothPairingDetailTest 90 mBluetoothDevice = mBluetoothAdapter.getRemoteDevice(TEST_DEVICE_ADDRESS); in setUp() 222 mFragment.mSelectedDevice = mBluetoothDevice; in onConnectionStateChanged_connected_finish() 223 doReturn(mBluetoothDevice).when(mCachedBluetoothDevice).getDevice(); in onConnectionStateChanged_connected_finish()
|
D | ConnectedBluetoothDeviceUpdaterTest.java | 67 private BluetoothDevice mBluetoothDevice; field in ConnectedBluetoothDeviceUpdaterTest 89 when(mCachedBluetoothDevice.getDevice()).thenReturn(mBluetoothDevice); in setUp() 243 mBluetoothDeviceUpdater.mPreferenceMap.put(mBluetoothDevice, btPreference); in addPreference_addPreference_shouldHideSecondTarget()
|
D | AvailableMediaBluetoothDeviceUpdaterTest.java | 64 private BluetoothDevice mBluetoothDevice; field in AvailableMediaBluetoothDeviceUpdaterTest 88 when(mCachedBluetoothDevice.getDevice()).thenReturn(mBluetoothDevice); in setUp()
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/sound/ |
D | HandsFreeProfileOutputPreferenceControllerTest.java | 106 private BluetoothDevice mBluetoothDevice; field in HandsFreeProfileOutputPreferenceControllerTest 134 mBluetoothDevice = spy(mBluetoothAdapter.getRemoteDevice(TEST_DEVICE_ADDRESS_1)); in setUp() 135 when(mBluetoothDevice.getName()).thenReturn(TEST_DEVICE_NAME_1); in setUp() 136 when(mBluetoothDevice.isConnected()).thenReturn(true); in setUp() 192 mController.setActiveBluetoothDevice(mBluetoothDevice); in setActiveBluetoothDevice_btDeviceWithoutHisyncId_shouldSetBtDeviceActive() 194 verify(mHeadsetProfile).setActiveDevice(mBluetoothDevice); in setActiveBluetoothDevice_btDeviceWithoutHisyncId_shouldSetBtDeviceActive() 195 verify(mHearingAidProfile, never()).setActiveDevice(mBluetoothDevice); in setActiveBluetoothDevice_btDeviceWithoutHisyncId_shouldSetBtDeviceActive() 221 mController.setActiveBluetoothDevice(mBluetoothDevice); in setActiveBluetoothDevice_inNormalMode_shouldNotSetActiveDeviceToHeadsetProfile() 250 mProfileConnectedDevices.add(mBluetoothDevice); in updateState_oneHeadsetsAvailableAndActivated_shouldSetDeviceName() 252 when(mHeadsetProfile.getActiveDevice()).thenReturn(mBluetoothDevice); in updateState_oneHeadsetsAvailableAndActivated_shouldSetDeviceName() [all …]
|
D | AudioOutputSwitchPreferenceControllerTest.java | 111 private BluetoothDevice mBluetoothDevice; field in AudioOutputSwitchPreferenceControllerTest 143 mBluetoothDevice = spy(mBluetoothAdapter.getRemoteDevice(TEST_DEVICE_ADDRESS_1)); in setUp() 144 when(mBluetoothDevice.getName()).thenReturn(TEST_DEVICE_NAME_1); in setUp() 145 when(mBluetoothDevice.isConnected()).thenReturn(true); in setUp() 257 mController.mConnectedDevices.add(mBluetoothDevice); in findActiveHearingAidDevice_leftActiveDevice_returnLeftDeviceAsActiveHapDevice() 262 when(mHeadsetProfile.getActiveDevice()).thenReturn(mBluetoothDevice); in findActiveHearingAidDevice_leftActiveDevice_returnLeftDeviceAsActiveHapDevice() 275 mController.mConnectedDevices.add(mBluetoothDevice); in findActiveHearingAidDevice_rightActiveDevice_returnRightDeviceAsActiveHapDevice() 280 when(mHeadsetProfile.getActiveDevice()).thenReturn(mBluetoothDevice); in findActiveHearingAidDevice_rightActiveDevice_returnRightDeviceAsActiveHapDevice() 293 mController.mConnectedDevices.add(mBluetoothDevice); in findActiveHearingAidDevice_twoActiveDevice_returnActiveDeviceInConnectedDevices() 298 when(mHeadsetProfile.getActiveDevice()).thenReturn(mBluetoothDevice); in findActiveHearingAidDevice_twoActiveDevice_returnActiveDeviceInConnectedDevices() [all …]
|
D | MediaOutputPreferenceControllerTest.java | 106 private BluetoothDevice mBluetoothDevice; field in MediaOutputPreferenceControllerTest 134 mBluetoothDevice = spy(mBluetoothAdapter.getRemoteDevice(TEST_DEVICE_ADDRESS_1)); in setUp() 135 when(mBluetoothDevice.getName()).thenReturn(TEST_DEVICE_NAME_1); in setUp() 136 when(mBluetoothDevice.isConnected()).thenReturn(true); in setUp() 196 mProfileConnectedDevices.add(mBluetoothDevice); in updateState_withConnectedBtDevice_preferenceVisible() 205 when(mA2dpProfile.getActiveDevice()).thenReturn(mBluetoothDevice); in updateState_withConnectedBtDevice_preferenceVisible() 219 mProfileConnectedDevices.add(mBluetoothDevice); in updateState_withConnectedBtDevice_withoutActiveBtDevice_setDefaultSummary() 239 mProfileConnectedDevices.add(mBluetoothDevice); in updateState_withActiveBtDevice_setActivatedDeviceName() 242 when(mA2dpProfile.getActiveDevice()).thenReturn(mBluetoothDevice); in updateState_withActiveBtDevice_setActivatedDeviceName() 338 when(mA2dpProfile.getActiveDevice()).thenReturn(mBluetoothDevice); in findActiveDevice_onlyA2dpDeviceActive_returnA2dpDevice() [all …]
|
/packages/services/Car/tests/carservice_unit_test/src/com/android/car/trust/ |
D | CarTrustAgentEnrollmentServiceTest.java | 73 private BluetoothDevice mBluetoothDevice; field in CarTrustAgentEnrollmentServiceTest 98 mBluetoothDevice = BluetoothAdapter.getDefaultAdapter().getRemoteDevice(ADDRESS); in setUp() 107 mCarTrustAgentEnrollmentService.onRemoteDeviceConnected(mBluetoothDevice); in setUp() 138 verify(mMockCarTrustAgentBleManager).sendEnrollmentMessage(eq(mBluetoothDevice), in testEncryptionHandshake() 147 verify(mMockCarTrustAgentBleManager).sendEnrollmentMessage(eq(mBluetoothDevice), in testEncryptionHandshake() 154 verify(mMockCarTrustAgentBleManager).sendEnrollmentMessage(eq(mBluetoothDevice), in testEncryptionHandshake() 158 mCarTrustAgentEnrollmentService.enrollmentHandshakeAccepted(mBluetoothDevice); in testEncryptionHandshake() 159 verify(mMockCarTrustAgentBleManager).sendEnrollmentMessage(eq(mBluetoothDevice), in testEncryptionHandshake() 188 verify(mMockCarTrustAgentBleManager).sendEnrollmentMessage(eq(mBluetoothDevice), any(), in testOnEscrowTokenActiveStateChange_true_addTrustedDevice() 288 mCarTrustAgentEnrollmentService.enrollmentHandshakeAccepted(mBluetoothDevice); in setupEncryptionHandshake()
|
/packages/apps/Car/Settings/tests/robotests/src/com/android/car/settings/security/ |
D | AddTrustedDeviceActivityTest.java | 69 private BluetoothDevice mBluetoothDevice; field in AddTrustedDeviceActivityTest 83 mBluetoothDevice = BluetoothAdapter.getDefaultAdapter().getRemoteDevice(ADDRESS); in setUp() 106 outState.putParcelable(BLUETOOTH_DEVICE_KEY, mBluetoothDevice); in onStart_saveInstanceState_deviceConnected_doNotStartAdvertising() 137 outState.putParcelable(BLUETOOTH_DEVICE_KEY, mBluetoothDevice); in onStart_has_activated_handle_finish() 153 enrollmentCallBack.getValue().onAuthStringAvailable(mBluetoothDevice, "123"); in onAuthStringAvailable_createDialog() 191 bleCallBack.getValue().onBleEnrollmentDeviceDisconnected(mBluetoothDevice); in onBluetoothDeviceDisconnected_finish() 204 bleCallBack.getValue().onBleEnrollmentDeviceConnected(mBluetoothDevice); in onPairingCodeDialogConfirmed_handshakeAccepted() 206 verify(mMockCarTrustAgentEnrollmentManager).enrollmentHandshakeAccepted(mBluetoothDevice); in onPairingCodeDialogConfirmed_handshakeAccepted() 223 bleCallBack.getValue().onBleEnrollmentDeviceConnected(mBluetoothDevice); in onStart_onEscrowTokenActiveStateChanged_activated_finish()
|
/packages/apps/Car/Settings/src/com/android/car/settings/security/ |
D | AddTrustedDeviceActivity.java | 67 private BluetoothDevice mBluetoothDevice; field in AddTrustedDeviceActivity 118 mBluetoothDevice = device; 127 mBluetoothDevice = null; 145 mCarTrustAgentEnrollmentManager.enrollmentHandshakeAccepted(mBluetoothDevice); 165 mBluetoothDevice = savedInstanceState.getParcelable(BLUETOOTH_DEVICE_KEY); in onCreate() 186 if (mBluetoothDevice == null) { in onStart() 214 savedInstanceState.putParcelable(BLUETOOTH_DEVICE_KEY, mBluetoothDevice); in onSaveInstanceState()
|
/packages/services/Car/tests/EmbeddedKitchenSinkApp/src/com/google/android/car/kitchensink/bluetooth/ |
D | MapMceTestFragment.java | 71 TextView mBluetoothDevice; field in MapMceTestFragment 88 mBluetoothDevice = (TextView) v.findViewById(R.id.bluetoothDevice); in onCreateView() 149 disconnectDevice(mBluetoothDevice.getText().toString()); in onCreateView() 198 mBluetoothDevice.getText().toString()); in getMessages() 216 mBluetoothDevice.getText().toString()); in getUploadingFeatureValue() 244 mBluetoothDevice.getText().toString()); in sendMessage() 257 if (mBluetoothDevice == null) { in sendMessage() 297 mBluetoothDevice.setText(connectedDevices.get(0).getAddress()); in onServiceConnected() 318 mBluetoothDevice.setText(((BluetoothDevice) intent.getParcelableExtra( in onReceive() 322 mBluetoothDevice.setText("Disconnected"); in onReceive()
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/accessibility/ |
D | AccessibilityHearingAidPreferenceControllerTest.java | 74 private BluetoothDevice mBluetoothDevice; field in AccessibilityHearingAidPreferenceControllerTest 162 when(mCachedBluetoothDevice.getDevice()).thenReturn(mBluetoothDevice); in handleHearingAidPreferenceClick_withHearingAid_launchBluetoothDeviceDetailSetting() 187 when(mLocalBluetoothManager.getCachedDeviceManager().isSubDevice(mBluetoothDevice)) in getConnectedHearingAidDevice_doNotReturnSubDevice() 206 mBluetoothDevice = mBluetoothAdapter.getRemoteDevice(TEST_DEVICE_ADDRESS); in setupHearingAidEnvironment() 209 when(mCachedDeviceManager.findDevice(mBluetoothDevice)).thenReturn(mCachedBluetoothDevice); in setupHearingAidEnvironment() 222 deviceList.add(mBluetoothDevice); in generateHearingAidDeviceList()
|
/packages/services/Car/service/src/com/android/car/ |
D | BluetoothProfileInhibitManager.java | 92 private final BluetoothDevice mBluetoothDevice; field in BluetoothProfileInhibitManager.BluetoothConnection 97 mBluetoothDevice = device; in BluetoothConnection() 101 return mBluetoothDevice; in getDevice() 117 return Objects.equals(mBluetoothDevice, otherParams.mBluetoothDevice) in equals() 123 return Objects.hash(mBluetoothDevice, mBluetoothProfile); in hashCode() 137 return mBluetoothDevice + "/" + mBluetoothProfile; in encode()
|
/packages/apps/Car/Dialer/src/com/android/car/dialer/ui/ |
D | TelecomActivityViewModel.java | 62 private BluetoothDevice mBluetoothDevice; field in TelecomActivityViewModel 102 if (!hfpDeviceList.contains(mBluetoothDevice)) { in TelecomActivityViewModel() 103 mBluetoothDevice = hfpDeviceList.get(0); in TelecomActivityViewModel() 107 if (mBluetoothDevice != null) { in TelecomActivityViewModel() 108 mBluetoothDevice = null; in TelecomActivityViewModel()
|
D | TelecomActivity.java | 80 private BluetoothDevice mBluetoothDevice; field in TelecomActivity
|