[common][bluetooth] fix block issue on rpi4 05/310505/2
authorchen <chen89.chen@samsung.com>
Tue, 30 Apr 2024 05:18:07 +0000 (13:18 +0800)
committerchen chen <chen89.chen@samsung.com>
Tue, 30 Apr 2024 05:21:17 +0000 (05:21 +0000)
Change-Id: I079b1a9e740d54cbe23ba0021e57e05e785088ee
Signed-off-by: chen <chen89.chen@samsung.com>
common/tct-bluetooth-tizen-tests/bluetooth/support/unitcommon.js

index 20fcfe78be18a02a8ccb6e36d0b6e258c486b7f4..2a2a4ffa1c053494ea94236f429435d4a705195a 100755 (executable)
@@ -43,9 +43,17 @@ NOT_FOUND_EXCEPTION = {name: 'NotFoundError'};
 INVALID_VALUES_EXCEPTION = {name: 'InvalidValuesError'};\r
 IO_EXCEPTION = {name: 'IOError'};\r
 SECURITY_EXCEPTION = {name: 'SecurityError'};\r
-BT_SUPPORT = webapis.featureconfig.getFeatureConfigBool("com.samsung/featureconf/bluetooth.support");\r
-LE_SUPPORT = webapis.featureconfig.getFeatureConfigBool("com.samsung/featureconf/bluetooth_le_supported");\r
-LE_GATT_SUPPORT = webapis.featureconfig.getFeatureConfigBool("com.samsung/featureconf/bluetooth_le_gatt_client_supported");\r
+\r
+try {\r
+    BT_SUPPORT = webapis.featureconfig.getFeatureConfigBool("com.samsung/featureconf/bluetooth.support");\r
+    LE_SUPPORT = webapis.featureconfig.getFeatureConfigBool("com.samsung/featureconf/bluetooth_le_supported");\r
+    LE_GATT_SUPPORT = webapis.featureconfig.getFeatureConfigBool("com.samsung/featureconf/bluetooth_le_gatt_client_supported");\r
+} catch(e) {\r
+    console.log(" webapis.featureconfig.getFeatureConfigBool Exception. reason : " + e.message + "(" + e.code + ")");\r
+    BT_SUPPORT = tizen.systeminfo.getCapability("http://tizen.org/feature/network.bluetooth");\r
+    LE_SUPPORT = tizen.systeminfo.getCapability("http://tizen.org/feature/network.bluetooth.le");\r
+    LE_GATT_SUPPORT = tizen.systeminfo.getCapability("http://tizen.org/feature/network.bluetooth.le.gatt.client");\r
+}\r
 \r
 (function () {\r
    var head_src = document.head.innerHTML;\r