Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(198)

Side by Side Diff: third_party/WebKit/LayoutTests/bluetooth/descriptor/readValue/gen-io-op-fails.html

Issue 2637343002: Implement WebBluetooth descriptor.readValue() (Closed)
Patch Set: run bad_message_reasons Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 <!-- Generated by //third_party/WebKit/LayoutTests/bluetooth/generate.py -->
2 <!DOCTYPE html>
3 <script src="../../../resources/testharness.js"></script>
4 <script src="../../../resources/testharnessreport.js"></script>
5 <script src="../../../resources/bluetooth/bluetooth-helpers.js"></script>
6 <script>
7 'use strict';
8 promise_test(
9 () => {
10 return setBluetoothFakeAdapter('FailingGATTOperationsAdapter')
11 .then(
12 () => requestDeviceWithKeyDown(
13 {filters: [{services: [errorUUID(0xA0)]}]}))
14 .then(device => device.gatt.connect())
15 .then(gattServer => gattServer.getPrimaryService(errorUUID(0xA0)))
16 .then(
17 service => {
18 service.getCharacteristic(errorUUID(0xA1))
19 .then(characteristic => {
20 let tests = Promise.resolve();
21 gatt_errors_tests.forEach(testSpec => {
22 tests =
23 tests
24 .then(
25 () => characteristic.getDescriptor(
26 testSpec.uuid))
27 .then(
28 descriptor =>
29 assert_promise_rejects_with_message(
30 descriptor.readValue(),
31 testSpec.error,
32 testSpec.testName));
33 });
34 return tests;
35 })})},
36 'readValue fails. Should reject with appropriate error.');
37
38 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698