| OLD | NEW |
| 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 Loading... |
| 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(); |
| OLD | NEW |