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

Unified Diff: LayoutTests/storage/indexeddb/version-change-abort-expected.txt

Issue 243523003: Fire window.onerror for uncaught IndexedDB errors (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebased and linkage fix Created 5 years, 3 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 side-by-side diff with in-line comments
Download patch
Index: LayoutTests/storage/indexeddb/version-change-abort-expected.txt
diff --git a/LayoutTests/storage/indexeddb/version-change-abort-expected.txt b/LayoutTests/storage/indexeddb/version-change-abort-expected.txt
index 72ad97435f6c36203729cccb9675cad400f2d3d1..b29b0f8e3e2781c5b947aba847b3bb913ea692ac 100644
--- a/LayoutTests/storage/indexeddb/version-change-abort-expected.txt
+++ b/LayoutTests/storage/indexeddb/version-change-abort-expected.txt
@@ -1,4 +1,5 @@
-CONSOLE ERROR: line 52: Uncaught Error: This should *NOT* be caught!
+CONSOLE ERROR: line 58: Uncaught Error: This should not be caught
+CONSOLE ERROR: line 1: AbortError: Version change transaction was aborted in upgradeneeded event handler.
Ensure that aborted VERSION_CHANGE transactions are completely rolled back
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
@@ -8,19 +9,26 @@ dbname = "version-change-abort.html"
indexedDB.deleteDatabase(dbname)
indexedDB.open(dbname)
PASS trans instanceof IDBTransaction is true
-store = db.createObjectStore('store1')
-setVersion1 complete
+db.createObjectStore('store1')
+openRequest1 complete
PASS db.version is 1
vcreq = indexedDB.open(dbname, 2)
-setVersion2() callback
+openRequest2() callback
PASS db.version is 2
PASS vcreq.transaction instanceof IDBTransaction is true
-store = db.deleteObjectStore('store1')
-store = db.createObjectStore('store2')
+db.deleteObjectStore('store1')
+db.createObjectStore('store2')
raising exception
+PASS Got expected error: 'Uncaught Error: This should not be caught'
+PASS sawGlobalErrorUncaughtException is true
-setVersion2Abort() callback
+openRequest2Error() callback
+PASS sawGlobalErrorUncaughtException is true
+PASS sawTransactionAbort is true
+PASS Got expected error: 'AbortError: Version change transaction was aborted in upgradeneeded event handler.'
+
+Verify rollback:
request = indexedDB.open(dbname)
PASS db.version is 1
PASS db.objectStoreNames.contains('store1') is true

Powered by Google App Engine
This is Rietveld 408576698