/cts/tests/tests/bluetooth/src/android/bluetooth/cts/ |
D | BluetoothAdapterTest.java | 98 private BluetoothAdapter mAdapter; field in BluetoothAdapterTest 107 mAdapter = mContext.getSystemService(BluetoothManager.class).getAdapter(); in setUp() 108 assertNotNull(mAdapter); in setUp() 187 assertTrue(BTAdapterUtils.disableAdapter(mAdapter, mContext)); in enableDisable() 188 assertTrue(BTAdapterUtils.enableAdapter(mAdapter, mContext)); in enableDisable() 196 assertTrue(BTAdapterUtils.enableAdapter(mAdapter, mContext)); in getAddress() 197 assertTrue(BluetoothAdapter.checkBluetoothAddress(mAdapter.getAddress())); in getAddress() 200 assertThrows(SecurityException.class, () -> mAdapter.getAddress()); in getAddress() 208 assertTrue(BTAdapterUtils.enableAdapter(mAdapter, mContext)); in setName_getName() 215 String name = mAdapter.getName(); in setName_getName() [all …]
|
D | BluetoothCddTest.java | 52 private BluetoothAdapter mAdapter; field in BluetoothCddTest 61 mAdapter = TestUtils.getBluetoothAdapterOrDie(); in setUp() 63 assertThat(BTAdapterUtils.enableAdapter(mAdapter, mContext)).isTrue(); in setUp() 71 if (mAdapter != null && mAdapter.getState() != BluetoothAdapter.STATE_OFF) { in tearDown() 72 if (mAdapter.getState() == BluetoothAdapter.STATE_ON) { in tearDown() 73 assertThat(BTAdapterUtils.disableAdapter(mAdapter, mContext)).isTrue(); in tearDown() 79 mAdapter = null; in tearDown() 88 assertThat(mAdapter.getSupportedProfiles()).contains(BluetoothProfile.GATT); in C_3_BleRequirements() 96 if (mAdapter.isLeAudioSupported() != BluetoothStatusCodes.FEATURE_SUPPORTED) { in C_7_LeAudioUnicastRequirements() 97 assertThat(mAdapter.getSupportedProfiles()).doesNotContain(BluetoothProfile.LE_AUDIO); in C_7_LeAudioUnicastRequirements() [all …]
|
D | BluetoothHeadsetTest.java | 63 private BluetoothAdapter mAdapter; field in BluetoothHeadsetTest 87 mAdapter = manager.getAdapter(); in setUp() 88 assertTrue(BTAdapterUtils.enableAdapter(mAdapter, mContext)); in setUp() 95 mAdapter.getProfileProxy(mContext, new BluetoothHeadsetServiceListener(), in setUp() 104 if (mAdapter != null && mBluetoothHeadset != null) { in tearDown() 105 mAdapter.closeProfileProxy(BluetoothProfile.HEADSET, mBluetoothHeadset); in tearDown() 109 mAdapter = null; in tearDown() 120 mAdapter.closeProfileProxy(BluetoothProfile.HEADSET, mBluetoothHeadset); in closeProfileProxy() 152 BluetoothDevice testDevice = mAdapter.getRemoteDevice("00:11:22:AA:BB:CC"); in getConnectionState() 164 BluetoothDevice testDevice = mAdapter.getRemoteDevice("00:11:22:AA:BB:CC"); in isAudioConnected() [all …]
|
D | BluetoothHidHostTest.java | 75 private BluetoothAdapter mAdapter; field in BluetoothHidHostTest 99 mAdapter = manager.getAdapter(); in setUp() 100 assertTrue(BTAdapterUtils.enableAdapter(mAdapter, mContext)); in setUp() 107 mAdapter.getProfileProxy( in setUp() 116 if (mAdapter != null && mHidHost != null) { in tearDown() 117 mAdapter.closeProfileProxy(BluetoothProfile.HID_HOST, mHidHost); in tearDown() 125 mAdapter = null; in tearDown() 135 mAdapter.closeProfileProxy(BluetoothProfile.HID_HOST, mHidHost); in closeProfileProxy() 146 assertTrue(BTAdapterUtils.disableAdapter(mAdapter, mContext)); in getConnectedDevices() 159 assertTrue(BTAdapterUtils.disableAdapter(mAdapter, mContext)); in getDevicesMatchingConnectionStates() [all …]
|
D | BluetoothPbapClientTest.java | 62 private BluetoothAdapter mAdapter; field in BluetoothPbapClientTest 86 mAdapter = manager.getAdapter(); in setUp() 87 assertTrue(BTAdapterUtils.enableAdapter(mAdapter, mContext)); in setUp() 94 mAdapter.getProfileProxy(mContext, new BluetoothPbapClientServiceListener(), in setUp() 103 if (mAdapter != null && mBluetoothPbapClient != null) { in tearDown() 104 mAdapter.closeProfileProxy(BluetoothProfile.PBAP_CLIENT, in tearDown() 109 mAdapter = null; in tearDown() 119 mAdapter.closeProfileProxy(BluetoothProfile.PBAP_CLIENT, mBluetoothPbapClient); in closeProfileProxy() 130 assertTrue(BTAdapterUtils.disableAdapter(mAdapter, mContext)); in getConnectedDevices() 143 BluetoothDevice testDevice = mAdapter.getRemoteDevice("00:11:22:AA:BB:CC"); in getConnectionPolicy() [all …]
|
D | BluetoothHeadsetClientTest.java | 63 private BluetoothAdapter mAdapter; field in BluetoothHeadsetClientTest 87 mAdapter = manager.getAdapter(); in setUp() 88 assertTrue(BTAdapterUtils.enableAdapter(mAdapter, mContext)); in setUp() 95 mAdapter.getProfileProxy(mContext, new BluetoothHeadsetClientServiceListener(), in setUp() 104 if (mAdapter != null && mBluetoothHeadsetClient != null) { in tearDown() 105 mAdapter.closeProfileProxy(BluetoothProfile.HEADSET_CLIENT, in tearDown() 110 mAdapter = null; in tearDown() 120 mAdapter.closeProfileProxy(BluetoothProfile.HEADSET_CLIENT, mBluetoothHeadsetClient); in closeProfileProxy() 131 assertTrue(BTAdapterUtils.disableAdapter(mAdapter, mContext)); in getConnectedDevices() 144 assertTrue(BTAdapterUtils.disableAdapter(mAdapter, mContext)); in getDevicesMatchingConnectionStates() [all …]
|
D | BluetoothMapClientTest.java | 75 private BluetoothAdapter mAdapter; field in BluetoothMapClientTest 101 mAdapter = manager.getAdapter(); in setUp() 102 assertTrue(BTAdapterUtils.enableAdapter(mAdapter, mContext)); in setUp() 109 mAdapter.getProfileProxy(mContext, new BluetoothMapClientServiceListener(), in setUp() 118 if (mAdapter != null && mBluetoothMapClient != null) { in tearDown() 119 mAdapter.closeProfileProxy(BluetoothProfile.MAP_CLIENT, in tearDown() 124 mAdapter = null; in tearDown() 134 mAdapter.closeProfileProxy(BluetoothProfile.MAP_CLIENT, mBluetoothMapClient); in closeProfileProxy() 145 assertTrue(BTAdapterUtils.disableAdapter(mAdapter, mContext)); in getConnectedDevices() 158 BluetoothDevice testDevice = mAdapter.getRemoteDevice("00:11:22:AA:BB:CC"); in getConnectionPolicy() [all …]
|
D | BluetoothHidDeviceTest.java | 75 private BluetoothAdapter mAdapter; field in BluetoothHidDeviceTest 97 mAdapter = manager.getAdapter(); in setUp() 98 assertTrue(BTAdapterUtils.enableAdapter(mAdapter, mContext)); in setUp() 105 mAdapter.getProfileProxy(mContext, new BluetoothHidServiceListener(), in setUp() 114 if (mAdapter != null && mBluetoothHidDevice != null) { in tearDown() 115 mAdapter.closeProfileProxy(BluetoothProfile.HID_DEVICE, mBluetoothHidDevice); in tearDown() 119 mAdapter = null; in tearDown() 130 mAdapter.closeProfileProxy(BluetoothProfile.HID_DEVICE, mBluetoothHidDevice); in closeProfileProxy() 145 assertTrue(BTAdapterUtils.disableAdapter(mAdapter, mContext)); in getDevicesMatchingConnectionStates() 159 BluetoothDevice testDevice = mAdapter.getRemoteDevice("00:11:22:AA:BB:CC"); in getConnectionState() [all …]
|
D | BluetoothPbapTest.java | 64 private BluetoothAdapter mAdapter; field in BluetoothPbapTest 89 mAdapter = manager.getAdapter(); in setUp() 90 assertTrue(BTAdapterUtils.enableAdapter(mAdapter, mContext)); in setUp() 97 mAdapter.getProfileProxy(mContext, new BluetoothPbapServiceListener(), in setUp() 106 if (mAdapter != null && mBluetoothPbap != null) { in tearDown() 107 mAdapter.closeProfileProxy(BluetoothProfile.PBAP, in tearDown() 112 mAdapter = null; in tearDown() 122 mAdapter.closeProfileProxy(BluetoothProfile.PBAP, mBluetoothPbap); in closeProfileProxy() 133 assertTrue(BTAdapterUtils.disableAdapter(mAdapter, mContext)); in getConnectedDevices() 146 BluetoothDevice testDevice = mAdapter.getRemoteDevice("00:11:22:AA:BB:CC"); in getConnectionState() [all …]
|
D | BluetoothMapTest.java | 64 private BluetoothAdapter mAdapter; field in BluetoothMapTest 90 mAdapter = manager.getAdapter(); in setUp() 91 assertTrue(BTAdapterUtils.enableAdapter(mAdapter, mContext)); in setUp() 98 mAdapter.getProfileProxy(mContext, new BluetoothMapServiceListener(), in setUp() 107 if (mAdapter != null && mBluetoothMap != null) { in tearDown() 112 mAdapter = null; in tearDown() 122 mAdapter.closeProfileProxy(BluetoothProfile.MAP, mBluetoothMap); in closeProfileProxy() 133 assertTrue(BTAdapterUtils.disableAdapter(mAdapter, mContext)); in getConnectedDevices() 146 BluetoothDevice testDevice = mAdapter.getRemoteDevice("00:11:22:AA:BB:CC"); in getConnectionPolicy() 152 assertTrue(BTAdapterUtils.disableAdapter(mAdapter, mContext)); in getConnectionPolicy() [all …]
|
D | BluetoothA2dpSinkTest.java | 60 private BluetoothAdapter mAdapter; field in BluetoothA2dpSinkTest 83 mAdapter = manager.getAdapter(); in setUp() 84 assertTrue(BTAdapterUtils.enableAdapter(mAdapter, mContext)); in setUp() 91 mAdapter.getProfileProxy(mContext, new BluetoothA2dpSinkServiceListener(), in setUp() 100 if (mAdapter != null && mBluetoothA2dpSink != null) { in tearDown() 101 mAdapter.closeProfileProxy(BluetoothProfile.A2DP_SINK, mBluetoothA2dpSink); in tearDown() 106 mAdapter = null; in tearDown() 116 mAdapter.closeProfileProxy(BluetoothProfile.A2DP_SINK, mBluetoothA2dpSink); in closeProfileProxy() 150 BluetoothDevice testDevice = mAdapter.getRemoteDevice("00:11:22:AA:BB:CC"); in getConnectionState() 166 BluetoothDevice testDevice = mAdapter.getRemoteDevice("00:11:22:AA:BB:CC"); in getConnectionPolicy() [all …]
|
D | BluetoothPanTest.java | 62 private BluetoothAdapter mAdapter; field in BluetoothPanTest 85 mAdapter = manager.getAdapter(); in setUp() 86 assertTrue(BTAdapterUtils.enableAdapter(mAdapter, mContext)); in setUp() 93 mAdapter.getProfileProxy(mContext, new BluetoothPanServiceListener(), in setUp() 102 if (mAdapter != null && mBluetoothPan != null) { in tearDown() 103 mAdapter.closeProfileProxy(BluetoothProfile.PAN, mBluetoothPan); in tearDown() 107 mAdapter = null; in tearDown() 118 mAdapter.closeProfileProxy(BluetoothProfile.PAN, mBluetoothPan); in closeProfileProxy() 129 assertTrue(BTAdapterUtils.disableAdapter(mAdapter, mContext)); in getConnectedDevices() 142 assertTrue(BTAdapterUtils.disableAdapter(mAdapter, mContext)); in getDevicesMatchingConnectionStates() [all …]
|
D | BluetoothVolumeControlTest.java | 69 private BluetoothAdapter mAdapter; field in BluetoothVolumeControlTest 153 mAdapter = manager.getAdapter(); in setUp() 154 assertTrue(BTAdapterUtils.enableAdapter(mAdapter, mContext)); in setUp() 172 mIsVolumeControlSupported = mAdapter.getProfileProxy(mContext, in setUp() 197 mAdapter = null; in tearDown() 209 mAdapter.closeProfileProxy(BluetoothProfile.VOLUME_CONTROL, mBluetoothVolumeControl); in closeProfileProxy() 220 assertTrue(BTAdapterUtils.disableAdapter(mAdapter, mContext)); in getConnectedDevices() 233 assertTrue(BTAdapterUtils.disableAdapter(mAdapter, mContext)); in getDevicesMatchingConnectionStates() 273 mTestDevice = mAdapter.getRemoteDevice("00:11:22:AA:BB:CC"); in setVolumeOffset() 287 mTestDevice = mAdapter.getRemoteDevice("00:11:22:AA:BB:CC"); in setDeviceVolume() [all …]
|
D | BluetoothA2dpTest.java | 72 private BluetoothAdapter mAdapter; field in BluetoothA2dpTest 94 mAdapter = manager.getAdapter(); in setUp() 95 assertTrue(BTAdapterUtils.enableAdapter(mAdapter, mContext)); in setUp() 103 mAdapter.getProfileProxy(mContext, new BluetoothA2dpServiceListener(), in setUp() 112 if (mAdapter != null && mBluetoothA2dp != null) { in tearDown() 113 mAdapter.closeProfileProxy(BluetoothProfile.A2DP, mBluetoothA2dp); in tearDown() 117 mAdapter = null; in tearDown() 128 mAdapter.closeProfileProxy(BluetoothProfile.A2DP, mBluetoothA2dp); in closeProfileProxy() 146 assertNotEquals(mAdapter, adapter); in closeProfileProxy_onDifferentAdapter() 180 BluetoothDevice testDevice = mAdapter.getRemoteDevice("00:11:22:AA:BB:CC"); in getConnectionState() [all …]
|
D | BluetoothServerSocketTest.java | 37 private BluetoothAdapter mAdapter; field in BluetoothServerSocketTest 50 mAdapter = manager.getAdapter(); in setUp() 51 assertTrue(BTAdapterUtils.enableAdapter(mAdapter, mContext)); in setUp() 52 mBluetoothServerSocket = mAdapter.listenUsingL2capChannel(); in setUp() 63 mAdapter = null; in tearDown()
|
D | BluetoothLeAudioTest.java | 69 private BluetoothAdapter mAdapter; field in BluetoothLeAudioTest 145 mAdapter = manager.getAdapter(); in setUp() 146 assertTrue(BTAdapterUtils.enableAdapter(mAdapter, mContext)); in setUp() 153 Assume.assumeTrue(mAdapter.isLeAudioSupported() == BluetoothStatusCodes.FEATURE_SUPPORTED); in setUp() 155 mAdapter.getProfileProxy(mContext, new BluetoothLeAudioServiceListener(), in setUp() 170 mAdapter = null; in tearDown() 180 mAdapter.closeProfileProxy(BluetoothProfile.LE_AUDIO, mBluetoothLeAudio); in closeProfileProxy() 191 assertTrue(BTAdapterUtils.disableAdapter(mAdapter, mContext)); in getConnectedDevices() 204 assertTrue(BTAdapterUtils.disableAdapter(mAdapter, mContext)); in getDevicesMatchingConnectionStates() 218 mTestDevice = mAdapter.getRemoteDevice("00:11:22:AA:BB:CC"); in getConnectionState() [all …]
|
D | BluetoothConfigTest.java | 54 private BluetoothAdapter mAdapter; field in BluetoothConfigTest 68 mAdapter = manager.getAdapter(); in setUp() 69 assertTrue(BTAdapterUtils.enableAdapter(mAdapter, mContext)); in setUp() 76 mAdapter = null; in tearDown() 100 final List<Integer> pList = mAdapter.getSupportedProfiles(); in profileEnabledValueInList() 149 mAdapter.isLeAudioSupported()) in profileEnabledValue() 151 mAdapter.isLeAudioBroadcastSourceSupported()) in profileEnabledValue() 153 mAdapter.isLeAudioBroadcastAssistantSupported()); in profileEnabledValue() 170 if (mAdapter.isLeAudioSupported() in bleCDDRequirement() 188 if (mAdapter.isLeAudioBroadcastSourceSupported() in bleCDDRequirement()
|
D | BluetoothSapTest.java | 60 private BluetoothAdapter mAdapter; field in BluetoothSapTest 85 mAdapter = mContext.getSystemService(BluetoothManager.class).getAdapter(); in setUp() 86 assertTrue(BTAdapterUtils.enableAdapter(mAdapter, mContext)); in setUp() 93 mAdapter.getProfileProxy(mContext, new BluetoothSapServiceListener(), in setUp() 100 if (mAdapter != null && mBluetoothSap != null) { in tearDown() 106 mAdapter = null; in tearDown() 118 mAdapter.closeProfileProxy(BluetoothProfile.SAP, mBluetoothSap); in closeProfileProxy() 162 BluetoothDevice testDevice = mAdapter.getRemoteDevice("00:11:22:AA:BB:CC"); in getConnectionState() 184 BluetoothDevice testDevice = mAdapter.getRemoteDevice("00:11:22:AA:BB:CC"); in setgetConnectionPolicy()
|
D | BluetoothCsipSetCoordinatorTest.java | 69 private BluetoothAdapter mAdapter; field in BluetoothCsipSetCoordinatorTest 132 mAdapter = manager.getAdapter(); in setUp() 133 assertTrue(BTAdapterUtils.enableAdapter(mAdapter, mContext)); in setUp() 141 assertEquals(BluetoothStatusCodes.FEATURE_SUPPORTED, mAdapter.isLeAudioSupported()); in setUp() 147 Assume.assumeTrue(mAdapter.getProfileProxy(mContext, in setUp() 171 mAdapter = null; in tearDown() 182 mAdapter.closeProfileProxy( in closeProfileProxy() 194 assertTrue(BTAdapterUtils.disableAdapter(mAdapter, mContext)); in getConnectedDevices() 207 assertTrue(BTAdapterUtils.disableAdapter(mAdapter, mContext)); in getDevicesMatchingConnectionStates() 221 mTestDevice = mAdapter.getRemoteDevice("00:11:22:AA:BB:CC"); in getConnectionState() [all …]
|
D | BluetoothLeBroadcastAssistantTest.java | 106 private BluetoothAdapter mAdapter; field in BluetoothLeBroadcastAssistantTest 171 mAdapter = TestUtils.getBluetoothAdapterOrDie(); in setUp() 172 assertTrue(BTAdapterUtils.enableAdapter(mAdapter, mContext)); in setUp() 179 Assume.assumeTrue(mAdapter.isLeAudioBroadcastAssistantSupported() == FEATURE_SUPPORTED); in setUp() 183 mAdapter.getProfileProxy(mContext, new ServiceListener(), in setUp() 189 if (mAdapter != null && mBluetoothLeBroadcastAssistant != null) { in tearDown() 190 mAdapter.closeProfileProxy(BluetoothProfile.LE_AUDIO_BROADCAST_ASSISTANT, in tearDown() 195 mAdapter = null; in tearDown() 206 mAdapter.closeProfileProxy( in closeProfileProxy() 218 BluetoothDevice testDevice = mAdapter.getRemoteLeDevice(TEST_ADDRESS_1, in addSource() [all …]
|
D | DistanceMeasurementSessionTest.java | 49 private BluetoothAdapter mAdapter; field in DistanceMeasurementSessionTest 68 mAdapter = TestUtils.getBluetoothAdapterOrDie(); in setUp() 69 assertTrue(BTAdapterUtils.enableAdapter(mAdapter, mContext)); in setUp() 71 Assume.assumeTrue(mAdapter.isDistanceMeasurementSupported() == FEATURE_SUPPORTED); in setUp() 77 mAdapter = null; in tearDown()
|
D | DistanceMeasurementManagerTest.java | 60 private BluetoothAdapter mAdapter; field in DistanceMeasurementManagerTest 86 mAdapter = TestUtils.getBluetoothAdapterOrDie(); in setUp() 87 assertTrue(BTAdapterUtils.enableAdapter(mAdapter, mContext)); in setUp() 89 Assume.assumeTrue(mAdapter.isDistanceMeasurementSupported() == FEATURE_SUPPORTED); in setUp() 90 mDistanceMeasurementManager = mAdapter.getDistanceMeasurementManager(); in setUp() 92 mDevice = mAdapter.getRemoteDevice("11:22:33:44:55:66"); in setUp() 98 mAdapter = null; in tearDown()
|
D | BluetoothLeBroadcastReceiveStateTest.java | 69 private BluetoothAdapter mAdapter; field in BluetoothLeBroadcastReceiveStateTest 81 mAdapter = TestUtils.getBluetoothAdapterOrDie(); in setUp() 82 assertTrue(BTAdapterUtils.enableAdapter(mAdapter, mContext)); in setUp() 85 mAdapter.isLeAudioBroadcastAssistantSupported() == FEATURE_SUPPORTED; in setUp() 94 mAdapter.isLeAudioBroadcastSourceSupported() == FEATURE_SUPPORTED; in setUp() 107 mAdapter = null; in tearDown() 115 mAdapter.getRemoteLeDevice(TEST_MAC_ADDRESS, TEST_SOURCE_ADDRESS_TYPE); in createBroadcastReceiveState()
|
/cts/apps/CtsVerifier/src/com/android/cts/verifier/ |
D | AbstractTestListActivity.java | 39 protected TestListAdapter mAdapter; field in AbstractTestListActivity 54 mAdapter = adapter; in setTestListAdapter() 55 setListAdapter(mAdapter); in setTestListAdapter() 56 mAdapter.loadTestResults(); in setTestListAdapter() 61 TestListItem item = mAdapter.getItem(position); in getIntent() 70 mAdapter.setTestResult(testResult); in setTestResult() 119 TestListItem testListItem = mAdapter.getItemByName(testResult.getName()); in handleLaunchTestResult() 120 if (mAdapter.isFoldableDevice() && testListItem != null in handleLaunchTestResult()
|
/cts/tests/tests/nfc/src/android/nfc/cts/ |
D | NfcAntennaLocationApiTest.java | 47 private NfcAdapter mAdapter; field in NfcAntennaLocationApiTest 54 mAdapter = NfcAdapter.getDefaultAdapter(mContext); in setUp() 55 assertNotNull(mAdapter); in setUp() 65 NfcAntennaInfo nfcAntennaInfo = mAdapter.getNfcAntennaInfo(); in testGetNfcAntennaInfo()
|