From: chen Date: Fri, 13 Dec 2024 18:23:08 +0000 (+0800) Subject: [tv][bluetooth]DF241203-01904 createBonding_bondingDevice reduce run time X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F28%2F316328%2F1;p=test%2Ftct%2Fweb%2Fapi.git [tv][bluetooth]DF241203-01904 createBonding_bondingDevice reduce run time Change-Id: I448a455648c89fbe9928540f3fea2e2f34863b71 Signed-off-by: chen --- diff --git a/common/tct-bluetooth-tizen-tests/bluetooth/BluetoothAdapter_createBonding_bondingDevice.html b/common/tct-bluetooth-tizen-tests/bluetooth/BluetoothAdapter_createBonding_bondingDevice.html index df200947c..8e006684c 100755 --- a/common/tct-bluetooth-tizen-tests/bluetooth/BluetoothAdapter_createBonding_bondingDevice.html +++ b/common/tct-bluetooth-tizen-tests/bluetooth/BluetoothAdapter_createBonding_bondingDevice.html @@ -64,6 +64,9 @@ t.step(function () { onstarted: t.step_func(function () { }), ondevicefound: t.step_func(function (device) { + if (device.address === REMOTE_DEVICE_ADDRESS) { + stopDiscovery(t, adapter, stopDiscoverySuccess1); + } }), ondevicedisappeared: t.step_func(function (address) { }), @@ -71,7 +74,7 @@ t.step(function () { if (devices.length > 0) { adapter.createBonding(REMOTE_DEVICE_ADDRESS, onBondingSuccess, onBondingError); } else { - setTimeout(setstopDiscoverySuccess, 1000); + setTimeout(stopDiscoverySuccess, 1000); } }) }; @@ -96,6 +99,9 @@ t.step(function () { assert_unreached("discoverDevicesError exception:" + e.message); }); + stopDiscoverySuccess1 = t.step_func(function () { + console.log("stopDiscoverySuccess1"); + }); stopDiscoverySuccess = t.step_func(function () { adapter.discoverDevices(discoverDevicesSuccessCallback, discoverDevicesError); });