| Index: third_party/WebKit/LayoutTests/bluetooth/getPrimaryServices/disconnect-called-during.html
|
| diff --git a/third_party/WebKit/LayoutTests/bluetooth/getPrimaryServices/device-goes-out-of-range.html b/third_party/WebKit/LayoutTests/bluetooth/getPrimaryServices/disconnect-called-during.html
|
| similarity index 52%
|
| copy from third_party/WebKit/LayoutTests/bluetooth/getPrimaryServices/device-goes-out-of-range.html
|
| copy to third_party/WebKit/LayoutTests/bluetooth/getPrimaryServices/disconnect-called-during.html
|
| index ba3ba17a70876ed09e8c277190243ba875e6eecd..3db3f4930d20e95c96f3e78699868d604755dcf5 100644
|
| --- a/third_party/WebKit/LayoutTests/bluetooth/getPrimaryServices/device-goes-out-of-range.html
|
| +++ b/third_party/WebKit/LayoutTests/bluetooth/getPrimaryServices/disconnect-called-during.html
|
| @@ -5,18 +5,18 @@
|
| <script>
|
| 'use strict';
|
| promise_test(() => {
|
| - return setBluetoothFakeAdapter('HeartRateAdapter')
|
| + return setBluetoothFakeAdapter('TwoHeartRateServicesAdapter')
|
| .then(() => requestDeviceWithKeyDown({
|
| filters: [{services: ['heart_rate']}],
|
| optionalServices: ['generic_access']}))
|
| .then(device => device.gatt.connect())
|
| .then(gattServer => {
|
| - return setBluetoothFakeAdapter('EmptyAdapter')
|
| - .then(() => assert_promise_rejects_with_message(
|
| - gattServer.getPrimaryServices(),
|
| - new DOMException('Bluetooth Device is no longer in range.',
|
| - 'NetworkError'),
|
| - 'Device went out of range.'));
|
| + let promise = assert_promise_rejects_with_message(
|
| + gattServer.getPrimaryServices(),
|
| + new DOMException('GATT Server disconnected while retrieving services.',
|
| + 'NetworkError'));
|
| + gattServer.disconnect();
|
| + return promise;
|
| });
|
| -}, 'Device goes out of range. Reject with NetworkError.');
|
| +}, 'disconnect() called during getPrimaryServices. Reject with NetworkError.');
|
| </script>
|
|
|