https://github.com/web-platform-tests/wpt
Raw File
Tip revision: ad6018d3a07c0903d6b00c72cd9bd0541d607c2b authored by Ms2ger on 27 February 2018, 14:20:49 UTC
Add a section on landing changes.
Tip revision: ad6018d
storagemanager-persisted-worker.js
importScripts('/resources/testharness.js');

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

done();
back to top