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

Side by Side Diff: LayoutTests/storage/indexeddb/resources/intversion-close-in-oncomplete.js

Issue 307653004: IndexedDB: Result of failed request should be |undefined| (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 6 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 if (this.importScripts) { 1 if (this.importScripts) {
2 importScripts('../../../resources/js-test.js'); 2 importScripts('../../../resources/js-test.js');
3 importScripts('shared.js'); 3 importScripts('shared.js');
4 } 4 }
5 5
6 description("Call db.close() in the complete handler for a version change transa ction, before the success event associated with the open call fires"); 6 description("Call db.close() in the complete handler for a version change transa ction, before the success event associated with the open call fires");
7 7
8 function test() 8 function test()
9 { 9 {
10 removeVendorPrefixes(); 10 removeVendorPrefixes();
(...skipping 28 matching lines...) Expand all
39 debug("transaction.oncomplete:"); 39 debug("transaction.oncomplete:");
40 evalAndLog("sawTransactionComplete = true"); 40 evalAndLog("sawTransactionComplete = true");
41 evalAndLog("db.close()"); 41 evalAndLog("db.close()");
42 }; 42 };
43 } 43 }
44 44
45 function openError(evt) 45 function openError(evt)
46 { 46 {
47 preamble(evt); 47 preamble(evt);
48 shouldBeTrue("sawTransactionComplete"); 48 shouldBeTrue("sawTransactionComplete");
49 shouldBeNull("event.target.result"); 49 shouldBeUndefined("event.target.result");
50 shouldBeNonNull("event.target.error");
50 shouldBeEqualToString("event.target.error.name", "AbortError"); 51 shouldBeEqualToString("event.target.error.name", "AbortError");
51 evalAndExpectException("transaction = db.transaction('os', 'readwrite')", "D OMException.INVALID_STATE_ERR", "'InvalidStateError'"); 52 evalAndExpectException("transaction = db.transaction('os', 'readwrite')", "D OMException.INVALID_STATE_ERR", "'InvalidStateError'");
52 finishJSTest(); 53 finishJSTest();
53 } 54 }
54 55
55 test(); 56 test();
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698