| Index: LayoutTests/storage/indexeddb/microtasks.html
|
| diff --git a/LayoutTests/storage/indexeddb/microtasks.html b/LayoutTests/storage/indexeddb/microtasks.html
|
| index fb081715f5b4b950623537218a1c6864a1aa1674..b09c9d2f549b07e86dd0db5cc309340e16bd61a2 100644
|
| --- a/LayoutTests/storage/indexeddb/microtasks.html
|
| +++ b/LayoutTests/storage/indexeddb/microtasks.html
|
| @@ -58,6 +58,30 @@ idb_test(
|
| );
|
|
|
| idb_test(
|
| + 'Transactions created in microtasks resolved by host behavior are deactivated when control returns to the event loop',
|
| + function(t, db) {
|
| + db.createObjectStore('store');
|
| + },
|
| + function(t, db) {
|
| + var aesAlgorithmKeyGen = {name: "AES-CBC", length: 128};
|
| + crypto.subtle.generateKey(aesAlgorithmKeyGen, false, ["encrypt"]).then(t.step_func(function() {
|
| + var tx = db.transaction('store');
|
| + var request = tx.objectStore('store').get(0);
|
| + request.onerror = t.unreached_func('request should not fail');
|
| + request.onsuccess = t.step_func(function() {
|
| + assert_true(isTransactionActive(tx, 'store'),
|
| + 'Transaction should be active during event dispatch');
|
| + setTimeout(t.step_func(function() {
|
| + assert_false(isTransactionActive(tx, 'store'),
|
| + 'Transaction should be inactive once control returns to event loop');
|
| + t.done();
|
| + }), 0);
|
| + });
|
| + }));
|
| + }
|
| +);
|
| +
|
| +idb_test(
|
| 'Transactions created in microtasks remain active in subsequent microtasks',
|
| function(t, db) {
|
| db.createObjectStore('store');
|
|
|