diff options
Diffstat (limited to 'testing/web-platform/tests/storage/storagemanager-persist.https.window.js')
-rw-r--r-- | testing/web-platform/tests/storage/storagemanager-persist.https.window.js | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/testing/web-platform/tests/storage/storagemanager-persist.https.window.js b/testing/web-platform/tests/storage/storagemanager-persist.https.window.js new file mode 100644 index 0000000000..13e17a16e1 --- /dev/null +++ b/testing/web-platform/tests/storage/storagemanager-persist.https.window.js @@ -0,0 +1,10 @@ +// META: title=StorageManager: persist() + +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.'); |