Move parseFontFaceDescriptor to CSSPropertyParser.cpp
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / http / tests / serviceworker / resources / indexeddb-worker.js
blobef89550b3e0b26d84df9b0e8f3c00ef8265179cb
1 var port;
2 self.addEventListener('message', function(e) {
3 var message = e.data;
4 if ('port' in message)
5 doIndexedDBTest(message.port);
6 });
8 function doIndexedDBTest(port) {
9 var delete_request = indexedDB.deleteDatabase('db');
10 delete_request.onsuccess = function() {
11 var open_request = indexedDB.open('db');
12 open_request.onupgradeneeded = function() {
13 var db = open_request.result;
14 db.createObjectStore('store');
16 open_request.onsuccess = function() {
17 var db = open_request.result;
18 var tx = db.transaction('store', 'readwrite');
19 var store = tx.objectStore('store');
20 store.put('value', 'key');
21 tx.oncomplete = function() {
22 port.postMessage('done');