mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-11-11 05:39:41 +02:00
Automatic update from web-platform-tests Reland "Add quota usage details tests for all other storage backends." This is a reland of 548e7b5e622ad79155ff95ef26738d7a40fe9397 Original change's description: > Add quota usage details tests for all other storage backends. > > IndexedDB test was included in parent CL. > > Bug: 904000 > Test: > Change-Id: Icc3462f13d0dce0197a8ec54f22d5ad794a51292 > Reviewed-on: https://chromium-review.googlesource.com/c/1334659 > Reviewed-by: Victor Costan <pwnall@chromium.org> > Reviewed-by: Joshua Bell <jsbell@chromium.org> > Commit-Queue: Jarryd Goodman <jarrydg@chromium.org> > Cr-Commit-Position: refs/heads/master@{#616398} Bug: 904000 Change-Id: I507ec17eabc8e323a7c6418075d4be4787d4c5df Reviewed-on: https://chromium-review.googlesource.com/c/1378805 Reviewed-by: Joshua Bell <jsbell@chromium.org> Commit-Queue: Jarryd Goodman <jarrydg@chromium.org> Cr-Commit-Position: refs/heads/master@{#617285} -- wpt-commits: 7e5cdeab733b40357f553704fddddf6c5f199c8b wpt-pr: 14531
12 lines
544 B
JavaScript
12 lines
544 B
JavaScript
// 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');
|