summaryrefslogtreecommitdiffstats
path: root/LayoutTests/storage/indexeddb/exception-in-event-aborts-expected.txt
diff options
context:
space:
mode:
Diffstat (limited to 'LayoutTests/storage/indexeddb/exception-in-event-aborts-expected.txt')
-rw-r--r--LayoutTests/storage/indexeddb/exception-in-event-aborts-expected.txt61
1 files changed, 61 insertions, 0 deletions
diff --git a/LayoutTests/storage/indexeddb/exception-in-event-aborts-expected.txt b/LayoutTests/storage/indexeddb/exception-in-event-aborts-expected.txt
new file mode 100644
index 0000000..25c91e2
--- /dev/null
+++ b/LayoutTests/storage/indexeddb/exception-in-event-aborts-expected.txt
@@ -0,0 +1,61 @@
+CONSOLE MESSAGE: line 65: Uncaught this exception is expected
+CONSOLE MESSAGE: line 65: Uncaught this exception is expected
+Test exceptions in IDBRequest handlers cause aborts.
+
+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
+webkitIndexedDB.open('exception-in-event-aborts')
+db = event.target.result
+db.setVersion('new version')
+setVersionSuccess():
+trans = event.target.result
+PASS trans !== null is true
+trans.oncomplete = startTest
+Deleted all object stores.
+store = db.createObjectStore('storeName', null)
+store.add({x: 'value', y: 'zzz'}, 'key')
+
+trans = db.transaction([], webkitIDBTransaction.READ_WRITE)
+trans.onabort = transactionAborted1
+trans.oncomplete = unexpectedCompleteCallback
+store = trans.objectStore('storeName')
+store.add({x: 'value2', y: 'zzz2'}, 'key2')
+
+event.preventDefault()
+Throwing
+
+PASS The transaction was aborted.
+trans = db.transaction([], webkitIDBTransaction.READ_WRITE)
+trans.onabort = transactionAborted2
+trans.oncomplete = unexpectedCompleteCallback
+store = trans.objectStore('storeName')
+store.add({x: 'value', y: 'zzz'}, 'key')
+
+event.preventDefault()
+Throwing
+
+PASS The transaction was aborted.
+trans = db.transaction([], webkitIDBTransaction.READ_WRITE)
+trans.onabort = unexpectedAbortCallback
+trans.oncomplete = transactionCompleted1
+store = trans.objectStore('storeName')
+store.add({x: 'value3', y: 'zzz3'}, 'key3')
+
+event.preventDefault()
+Throwing within a try block
+
+PASS The transaction completed.
+trans = db.transaction([], webkitIDBTransaction.READ_WRITE)
+trans.onabort = unexpectedAbortCallback
+trans.oncomplete = transactionCompleted2
+store = trans.objectStore('storeName')
+store.add({x: 'value4', y: 'zzz4'}, 'key4')
+FAIL Success function called unexpectedly.
+
+PASS The transaction completed.
+
+PASS successfullyParsed is true
+
+TEST COMPLETE
+