diff options
Diffstat (limited to 'testing/web-platform/tests/storage/estimate-usage-details.https.tentative.any.js')
-rw-r--r-- | testing/web-platform/tests/storage/estimate-usage-details.https.tentative.any.js | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/testing/web-platform/tests/storage/estimate-usage-details.https.tentative.any.js b/testing/web-platform/tests/storage/estimate-usage-details.https.tentative.any.js new file mode 100644 index 0000000000..2a1cea5fb8 --- /dev/null +++ b/testing/web-platform/tests/storage/estimate-usage-details.https.tentative.any.js @@ -0,0 +1,12 @@ +// META: title=StorageManager: estimate() should have usage details + +promise_test(async t => { + const estimate = await navigator.storage.estimate(); + assert_equals(typeof estimate, 'object'); + assert_true('usage' in estimate); + assert_equals(typeof estimate.usage, 'number'); + assert_true('quota' in estimate); + assert_equals(typeof estimate.quota, 'number'); + assert_true('usageDetails' in estimate); + assert_equals(typeof estimate.usageDetails, 'object'); +}, 'estimate() resolves to dictionary with members, including usageDetails'); |