https://github.com/web-platform-tests/wpt
Raw File
Tip revision: 613bc07af54f9af8d71ebd44e27362df6b684c56 authored by Thomas Guilbert on 21 March 2018, 19:11:48 UTC
Revert "Web Platform Tests: add /interfaces/webaudio.idl and corresponding test"
Tip revision: 613bc07
storagemanager-persist.https.html
<!DOCTYPE html>
<meta charset=utf-8>
<title>StorageManager: persist()</title>
<meta name="help" href="https://storage.spec.whatwg.org/#dom-storagemanager-persist">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script>

promise_test(function() {
    var promise = navigator.storage.persist();
    assert_true(promise instanceof Promise,
        'navigator.storage.persist() returned a Promise.');
    return promise.then(function(result) {
        assert_equals(typeof result, 'boolean', result + ' should be boolean');
    });
}, 'navigator.storage.persist() returns a promise that resolves.');

</script>
back to top