Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(480)

Side by Side Diff: LayoutTests/http/tests/cachestorage/script-tests/cache-storage.js

Issue 1032623008: Expose Cache Storage API in global window/worker scope (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Update webexposed expectations Created 5 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 importScripts('worker-testharness.js'); 1 if (self.importScripts) {
2 importScripts('../../resources/testharness-helpers.js'); 2 importScripts('/resources/testharness.js');
3 importScripts('/resources/testharness-helpers.js');
4 importScripts('../resources/test-helpers.js');
5 }
3 6
4 promise_test(function(t) { 7 promise_test(function(t) {
5 var cache_name = 'cache-storage/foo'; 8 var cache_name = 'cache-storage/foo';
6 return self.caches.delete(cache_name) 9 return self.caches.delete(cache_name)
7 .then(function() { 10 .then(function() {
8 return self.caches.open(cache_name); 11 return self.caches.open(cache_name);
9 }) 12 })
10 .then(function(cache) { 13 .then(function(cache) {
11 assert_true(cache instanceof Cache, 14 assert_true(cache instanceof Cache,
12 'CacheStorage.open should return a Cache.'); 15 'CacheStorage.open should return a Cache.');
(...skipping 165 matching lines...) Expand 10 before | Expand all | Expand 10 after
178 .then(function(cache_exists) { 181 .then(function(cache_exists) {
179 assert_true(cache_exists, 182 assert_true(cache_exists,
180 'CacheStorage names should be not be converted.'); 183 'CacheStorage names should be not be converted.');
181 }) 184 })
182 .then(function() { return self.caches.has(converted_name); }) 185 .then(function() { return self.caches.has(converted_name); })
183 .then(function(cache_exists) { 186 .then(function(cache_exists) {
184 assert_false(cache_exists, 187 assert_false(cache_exists,
185 'CacheStorage names should be not be converted.'); 188 'CacheStorage names should be not be converted.');
186 }); 189 });
187 }, 'CacheStorage names are DOMStrings not USVStrings'); 190 }, 'CacheStorage names are DOMStrings not USVStrings');
191
192 done();
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698