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

Side by Side Diff: third_party/WebKit/LayoutTests/storage/indexeddb/delete-in-upgradeneeded-close-in-open-success-expected.txt

Issue 2084053004: IndexedDB: Defer delete calls when there is a running upgrade (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased, made delete lists contain unique_ptrs Created 4 years, 5 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
1 Test that a deleteDatabase called while handling an upgradeneeded event is queue d and fires its events at the right time. The close() call to unblock the delete occurs in the open request's 'success' event handler. 1 Test that a deleteDatabase called while handling an upgradeneeded event is queue d and fires its events at the right time. The close() call to unblock the delete occurs in the open request's 'success' event handler.
2 2
3 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE ". 3 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE ".
4 4
5 5
6 dbname = "delete-in-upgradeneeded-close-in-open-success.html" 6 dbname = "delete-in-upgradeneeded-close-in-open-success.html"
7 indexedDB.deleteDatabase(dbname) 7 indexedDB.deleteDatabase(dbname)
8 8
9 initiallyDeleted(): 9 initiallyDeleted():
10 request = indexedDB.open(dbname, 1) 10 request = indexedDB.open(dbname, 1)
11 11
12 upgradeNeededCallback(): 12 upgradeNeededCallback():
13 PASS sawUpgradeNeeded is false 13 PASS sawUpgradeNeeded is false
14 sawUpgradeNeeded = true 14 sawUpgradeNeeded = true
15 PASS event.oldVersion is 0 15 PASS event.oldVersion is 0
16 PASS event.newVersion is 1 16 PASS event.newVersion is 1
17 db = event.target.result 17 db = event.target.result
18 request2 = indexedDB.deleteDatabase(dbname) 18 request2 = indexedDB.deleteDatabase(dbname)
19 request2.onsuccess = deleteSuccessCallback 19 request2.onsuccess = deleteSuccessCallback
20 20
21 openSuccess():
22 PASS sawUpgradeNeeded is true
23 PASS sawVersionChange is false
24 sawOpenSuccess = true
25 db = event.target.result
26 PASS db.version is 1
27
21 versionChangeCallback(): 28 versionChangeCallback():
22 PASS event.oldVersion is 1 29 PASS event.oldVersion is 1
23 PASS event.newVersion is null 30 PASS event.newVersion is null
24 PASS sawOpenSuccess is false 31 PASS sawOpenSuccess is true
25 sawVersionChange = true 32 sawVersionChange = true
26 Connection not closed at the end of 'versionchange', so 'blocked' should fire 33 Connection not closed at the end of 'versionchange', so 'blocked' should fire
27 34
28 openSuccess():
29 PASS sawUpgradeNeeded is true
30 PASS sawVersionChange is true
31 sawOpenSuccess = true
32 db = event.target.result
33 PASS db.version is 1
34 Closing here is too late to prevent the in-flight 'blocked' event, but it does u nblock the delete.
35 db.close()
36
37 deleteBlockedCallback(): 35 deleteBlockedCallback():
38 PASS sawVersionChange is true 36 PASS sawVersionChange is true
39 PASS sawOpenSuccess is true 37 PASS sawOpenSuccess is true
40 sawDeleteBlocked = true 38 sawDeleteBlocked = true
39 db.close()
41 40
42 deleteSuccessCallback(): 41 deleteSuccessCallback():
43 PASS sawVersionChange is true 42 PASS sawVersionChange is true
44 PASS sawDeleteBlocked is true 43 PASS sawDeleteBlocked is true
45 PASS successfullyParsed is true 44 PASS successfullyParsed is true
46 45
47 TEST COMPLETE 46 TEST COMPLETE
48 47
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698