summaryrefslogtreecommitdiffstats
path: root/LayoutTests/storage/indexeddb/data-corruption-expected.txt
blob: a02b54c2e18096311eaee72c98915b3bed8cc2d3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
Test that data inserted into IndexedDB does not get corrupted on disk.

On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".


webkitIndexedDB.open('data-corruption')
openSuccess():
db = event.target.result
db.setVersion('new version')
setVersionSuccess():
trans = event.target.result
PASS trans !== null is true
Deleted all object stores.
db.createObjectStore('storeName')
addData():
transaction = db.transaction([], webkitIDBTransaction.READ_WRITE)
request = transaction.objectStore('storeName').add({x: testDate}, 'key')
addData():
transaction = db.transaction([], webkitIDBTransaction.READ_ONLY)
request = transaction.objectStore('storeName').get('key')
PASS event.target.result.x.toString() == testDate.toString() is true
PASS successfullyParsed is true

TEST COMPLETE