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

Side by Side Diff: LayoutTests/storage/indexeddb/empty-filesystem-file-expected.txt

Issue 433983002: LayoutTests for writing empty Blob/File/FileList to IndexedDB. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Added Filesystem test. Created 6 years, 4 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
OLDNEW
(Empty)
1 Confirm that IndexedDB can store an empty File from the Filesystem API
2
3 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE ".
4
5
6 Got FileSystem:file__0:Temporary
7 indexedDB = self.indexedDB || self.webkitIndexedDB || self.mozIndexedDB || self. msIndexedDB || self.OIndexedDB;
8
9 dbname = "empty-filesystem-file.html"
10 indexedDB.deleteDatabase(dbname)
11 indexedDB.open(dbname)
12 store = db.createObjectStore('storeName')
13 store.put('value', 'key')
14
15 testEmptyFile():
16 file = window.emptyFile
17
18 validateResult(file):
19 transaction = db.transaction('storeName', 'readwrite')
20 store = transaction.objectStore('storeName')
21 store.put(file, 'filekey')
22 transaction = db.transaction('storeName', 'readwrite')
23 store = transaction.objectStore('storeName')
24 request = store.get('filekey')
25 PASS event.target.result.size == 0 is true
26 PASS successfullyParsed is true
27
28 TEST COMPLETE
29
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698