blob: a5e188544fd6455909500ea0fd26a98e69367ae7 [file] [log] [blame]
<!DOCTYPE html>
<script src="../../resources/testharness.js"></script>
<script src="../../resources/testharnessreport.js"></script>
<script src="../../resources/bluetooth/bluetooth-helpers.js"></script>
<script>
'use strict';
promise_test(() => {
return setBluetoothFakeAdapter('HeartRateAdapter')
.then(() => requestDeviceWithKeyDown({
filters: [{services: ['heart_rate']}]}))
.then(device => {
return Promise.all([device.gatt.connect(), device.gatt.connect()])
}).then(gattServers => {
assert_equals(gattServers[0], gattServers[1]);
});
}, 'Multiple connects should return the same gatt object.');
</script>