https://github.com/web-platform-tests/wpt
Raw File
Tip revision: a6f528f9ff00b8cd4e9526bae531c7eac75702fb authored by Yutaka Hirano on 26 April 2018, 22:52:40 UTC
fix
Tip revision: a6f528f
device-same-object.https.html
<!DOCTYPE html>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="/resources/testdriver.js"></script>
<script src="/resources/testdriver-vendor.js"></script>
<script src="/bluetooth/resources/bluetooth-helpers.js"></script>
<script>
'use strict';
const test_desc = '[SameObject] test for BluetoothRemoteGATTServer\'s device.';
let device, fake_peripheral;

bluetooth_test(() => getDiscoveredHealthThermometerDevice()
    .then(_ => ({device, fake_peripheral} = _))
    .then(() =>
      fake_peripheral.setNextGATTConnectionResponse({code: HCI_SUCCESS}))
    .then(() => device.gatt.connect())
    .then(gatt => assert_equals(gatt.device, gatt.device)),
    test_desc);
</script>
back to top