FileDocCategorySizeDatePackage
ExternalSharedPermsBTTest.javaAPI DocAndroid 5.1 API1396Thu Mar 12 22:22:12 GMT 2015com.android.framework.externalsharedpermsbttestapp

ExternalSharedPermsBTTest

public class ExternalSharedPermsBTTest extends android.test.InstrumentationTestCase

Fields Summary
private static final int
REQUEST_ENABLE_BT
Constructors Summary
Methods Summary
public voidtestRunBluetooth()
The use of bluetooth below is simply to simulate an activity that tries to use bluetooth upon creation, so we can verify whether permissions are granted and accessible to the activity once it launches.


                                         
      
    
        BluetoothAdapter mBluetoothAdapter = BluetoothAdapter.getDefaultAdapter();

        if ((mBluetoothAdapter != null) && (!mBluetoothAdapter.isEnabled())) {
            mBluetoothAdapter.getName();
        }