Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / storage / websql / multiple-transactions.js
blob2feb3ad2c2f4fc3424cf5a2b338773ca9efc5e35
1 var complete = 0;
3 function checkCompletion()
5 if (++complete == 2 && window.testRunner)
6 testRunner.notifyDone();
9 function runTest()
11 var db = openDatabaseWithSuffix("MultipleTransactionsTest", "1.0", "Test to make sure multiple transactions can be queued at once for an HTML5 database", 32768);
13 db.transaction(function(tx) {
14 log("Transaction 1 Started");
15 }, function(err) {
16 log("Transaction 1 Errored - " + err);
17 checkCompletion();
18 }, function() {
19 log("Transaction 1 Succeeded");
20 checkCompletion();
21 });
23 db.transaction(function(tx) {
24 log("Transaction 2 Started");
25 }, function(err) {
26 log("Transaction 2 Errored - " + err);
27 checkCompletion();
28 }, function() {
29 log("Transaction 2 Succeeded");
30 checkCompletion();
31 });