static BluetoothDevice foundDevice = null;
static BluetoothDevice bondedDevice = null;
static bool isBluetoothSupported = false;
+ static bool isBluetoothAudioCallSupported = false;
+ static bool isBluetoothAudioMediaSupported = false;
static string remote_addr = PreconditionUtils.GetBtAddress();
static bool pass_GetMaskFromUuid_RETURN_SERVICE_MASK = false;
{
LogUtils.Write(LogUtils.DEBUG, LogUtils.INFO, "Preconditions for each TEST");
Information.TryGetValue("http://tizen.org/feature/network.bluetooth", out isBluetoothSupported);
+ Information.TryGetValue("http://tizen.org/feature/network.bluetooth.audio.call", out isBluetoothAudioCallSupported);
+ Information.TryGetValue("http://tizen.org/feature/network.bluetooth.audio.media", out isBluetoothAudioMediaSupported);
flagDiscovery = false;
}
[TearDown]
pass_ManufacturerData_PROPERTY_READ_ONLY = true;
/* PASS condition for pass_GetProfile_RETURN_GET_INSTANCE */
- BluetoothAudio audioObject = bondedDevice.GetProfile<BluetoothAudio>();
- Assert.IsNotNull(audioObject, "AudioObject should not be null after getting the instance from GetProfile");
+ // In order to create BluetoothAudio instance, one of audio.call and audio.media features should be supported.
+ if (isBluetoothAudioCallSupported == true || isBluetoothAudioMediaSupported == true)
+ {
+ BluetoothAudio audioObject = bondedDevice.GetProfile<BluetoothAudio>();
+ Assert.IsNotNull(audioObject, "AudioObject should not be null after getting the instance from GetProfile");
+ }
BluetoothAvrcp avrcpObject = bondedDevice.GetProfile<BluetoothAvrcp>();
Assert.IsNotNull(avrcpObject, "AvrcpObject should not be null after getting the instance from GetProfile");