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

Side by Side Diff: third_party/WebKit/LayoutTests/bluetooth/requestDevice/acceptAllDevices/no-optional-services.html

Issue 2510323002: bluetooth: Implement acceptAllDevices (Closed)
Patch Set: Clean up Created 4 years, 1 month 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 <!DOCTYPE html>
scheib 2016/11/22 21:22:44 it's OK, but fyi I try to name the files so that v
ortuno 2016/11/23 06:03:08 That's much better, thanks. Done
2 <script src="../../../resources/testharness.js"></script>
3 <script src="../../../resources/testharnessreport.js"></script>
4 <script src="../../../resources/bluetooth/bluetooth-helpers.js"></script>
5 <script>
6 'use strict';
7 promise_test(() => {
8 return setBluetoothFakeAdapter('TwoHeartRateServicesAdapter')
9 .then(() => requestDeviceWithKeyDown({acceptAllDevices: true}))
10 .then(device => device.gatt.connect())
11 .then(gattServer => assert_promise_rejects_with_message(
12 gattServer.getPrimaryServices(),
13 new DOMException(
14 'Origin is not allowed to access any service. ' +
15 'Tip: Add the service UUID to \'optionalServices\' in ' +
16 'requestDevice() options. https://goo.gl/HxfxSQ',
17 'SecurityError')));
18 }, 'requestDevice called with acceptAllDevices: true and with no ' +
19 'optionalServices. Should not get access to any services.');
20 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698