https://github.com/web-platform-tests/wpt
Raw File
Tip revision: 04f42da4f68238031149ae1d0daa8d5b074f3c22 authored by Boris Zbarsky on 04 April 2018, 17:30:07 UTC
Remove support for the 'type' parameter to document.open.
Tip revision: 04f42da
not-processing-user-gesture.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 = 'Requires a user gesture.';
const expected = new DOMException(
    'Must be handling a user gesture to show a permission request.',
    'SecurityError');

bluetooth_test(() => setUpHealthThermometerAndHeartRateDevices()
    .then(() => assert_promise_rejects_with_message(
        navigator.bluetooth.requestDevice({filters:[{services:['heart_rate']}]}),
        expected, 'User gesture is required')),
    test_desc);
</script>
back to top