1 Check that transactions in different databases can run in parallel.
3 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
6 dbname = "transaction-coordination-across-databases.html"
11 indexedDB.deleteDatabase(dbname1)
14 indexedDB.deleteDatabase(dbname2)
17 indexedDB.open(dbname1, 1)
19 openOnUpgradeNeeded1():
20 db1 = event.target.result
21 store1 = db1.createObjectStore('store')
25 db1 = event.target.result
28 indexedDB.open(dbname2, 1)
31 db2 = event.target.result
32 store2 = db2.createObjectStore('store')
35 db2 = event.target.result
38 transaction1 = db1.transaction('store', 'readwrite')
39 transaction2 = db2.transaction('store', 'readwrite')
40 transaction1PutSuccess = false
41 transaction2PutSuccess = false
42 Keep both transactions alive until each has reported at least one successful operation
44 onTransactionComplete():
45 first transaction complete, still waiting...
47 onTransactionComplete():
48 PASS transaction1PutSuccess is true
49 PASS transaction2PutSuccess is true
52 PASS successfullyParsed is true