| OLD | NEW |
| 1 CONSOLE WARNING: 'DOMStringList.contains()' is deprecated, and will be removed. |
| 1 Test the basics of IndexedDB's IDBDatabase. | 2 Test the basics of IndexedDB's IDBDatabase. |
| 2 | 3 |
| 3 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE
". | 4 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE
". |
| 4 | 5 |
| 5 | 6 |
| 6 indexedDB = self.indexedDB || self.webkitIndexedDB || self.mozIndexedDB || self.
msIndexedDB || self.OIndexedDB; | 7 indexedDB = self.indexedDB || self.webkitIndexedDB || self.mozIndexedDB || self.
msIndexedDB || self.OIndexedDB; |
| 7 | 8 |
| 8 dbname = "database-basics.html" | 9 dbname = "database-basics.html" |
| 9 indexedDB.deleteDatabase(dbname) | 10 indexedDB.deleteDatabase(dbname) |
| 10 indexedDB.open(dbname) | 11 indexedDB.open(dbname) |
| 11 Test that you can't open a transaction while in a versionchange transaction | 12 Test that you can't open a transaction while in a versionchange transaction |
| 12 Expecting exception from db.transaction("doesntExist") | 13 Expecting exception from db.transaction("doesntExist") |
| 13 PASS Exception was thrown. | 14 PASS Exception was thrown. |
| 14 PASS code is DOMException.INVALID_STATE_ERR | 15 PASS code is DOMException.INVALID_STATE_ERR |
| 15 PASS ename is 'InvalidStateError' | 16 PASS ename is 'InvalidStateError' |
| 16 Exception message: Failed to execute 'transaction' on 'IDBDatabase': A version c
hange transaction is running. | 17 Exception message: Failed to execute 'transaction' on 'IDBDatabase': A version c
hange transaction is running. |
| 17 PASS db.version is 1 | 18 PASS db.version is 1 |
| 18 PASS db.name is "database-basics.html" | 19 PASS db.name is "database-basics.html" |
| 19 PASS db.objectStoreNames is [] | 20 PASS db.objectStoreNames is [] |
| 20 PASS db.objectStoreNames.length is 0 | 21 PASS db.objectStoreNames.length is 0 |
| 21 PASS db.objectStoreNames.contains('') is false | 22 PASS db.objectStoreNames.contains('') is false |
| 22 PASS db.objectStoreNames[0] is undefined. | 23 PASS db.objectStoreNames[0] is undefined. |
| 23 PASS db.objectStoreNames.item(0) is null | |
| 24 db.createObjectStore("test123") | 24 db.createObjectStore("test123") |
| 25 PASS db.objectStoreNames is ['test123'] | 25 PASS db.objectStoreNames is ['test123'] |
| 26 PASS db.objectStoreNames.length is 1 | 26 PASS db.objectStoreNames.length is 1 |
| 27 PASS db.objectStoreNames.contains('') is false | 27 PASS db.objectStoreNames.contains('') is false |
| 28 PASS db.objectStoreNames.contains('test456') is false | 28 PASS db.objectStoreNames.contains('test456') is false |
| 29 PASS db.objectStoreNames.contains('test123') is true | 29 PASS db.objectStoreNames.contains('test123') is true |
| 30 db.close() | 30 db.close() |
| 31 request = indexedDB.open(dbname, 2) | 31 request = indexedDB.open(dbname, 2) |
| 32 db = event.target.result | 32 db = event.target.result |
| 33 PASS db.version is 2 | 33 PASS db.version is 2 |
| (...skipping 19 matching lines...) Expand all Loading... |
| 53 PASS Exception was thrown. | 53 PASS Exception was thrown. |
| 54 PASS code is DOMException.INVALID_STATE_ERR | 54 PASS code is DOMException.INVALID_STATE_ERR |
| 55 PASS ename is 'InvalidStateError' | 55 PASS ename is 'InvalidStateError' |
| 56 Exception message: Failed to execute 'transaction' on 'IDBDatabase': The databas
e connection is closing. | 56 Exception message: Failed to execute 'transaction' on 'IDBDatabase': The databas
e connection is closing. |
| 57 Call twice, make sure it's harmless | 57 Call twice, make sure it's harmless |
| 58 db.close() | 58 db.close() |
| 59 PASS successfullyParsed is true | 59 PASS successfullyParsed is true |
| 60 | 60 |
| 61 TEST COMPLETE | 61 TEST COMPLETE |
| 62 | 62 |
| OLD | NEW |