| OLD | NEW |
| 1 Test for valid and invalid keypaths | 1 Test for valid and invalid keypaths |
| 2 | 2 |
| 3 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE
". | 3 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE
". |
| 4 | 4 |
| 5 | 5 |
| 6 indexedDB = self.indexedDB || self.webkitIndexedDB || self.mozIndexedDB || self.
msIndexedDB || self.OIndexedDB; | |
| 7 | |
| 8 dbname = "keypath-basics.html" | 6 dbname = "keypath-basics.html" |
| 9 indexedDB.deleteDatabase(dbname) | 7 indexedDB.deleteDatabase(dbname) |
| 10 indexedDB.open(dbname) | 8 indexedDB.open(dbname) |
| 11 store = db.createObjectStore('name') | 9 store = db.createObjectStore('name') |
| 12 PASS store.keyPath is null | 10 PASS store.keyPath is null |
| 13 Deleted all object stores. | 11 Deleted all object stores. |
| 14 store = db.createObjectStore('name', {keyPath: null}) | 12 store = db.createObjectStore('name', {keyPath: null}) |
| 15 PASS store.keyPath is null | 13 PASS store.keyPath is null |
| 16 index = store.createIndex('name', null) | 14 index = store.createIndex('name', null) |
| 17 PASS index.keyPath is 'null' | 15 PASS index.keyPath is 'null' |
| (...skipping 642 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 660 Exception message: Failed to execute 'createObjectStore' on 'IDBDatabase': The k
eyPath option is not a valid key path. | 658 Exception message: Failed to execute 'createObjectStore' on 'IDBDatabase': The k
eyPath option is not a valid key path. |
| 661 Expecting exception from db.createObjectStore('name').createIndex('name', '_\uFF
FF') | 659 Expecting exception from db.createObjectStore('name').createIndex('name', '_\uFF
FF') |
| 662 PASS Exception was thrown. | 660 PASS Exception was thrown. |
| 663 PASS code is DOMException.SYNTAX_ERR | 661 PASS code is DOMException.SYNTAX_ERR |
| 664 Exception message: Failed to execute 'createIndex' on 'IDBObjectStore': The keyP
ath argument contains an invalid key path. | 662 Exception message: Failed to execute 'createIndex' on 'IDBObjectStore': The keyP
ath argument contains an invalid key path. |
| 665 Deleted all object stores. | 663 Deleted all object stores. |
| 666 PASS successfullyParsed is true | 664 PASS successfullyParsed is true |
| 667 | 665 |
| 668 TEST COMPLETE | 666 TEST COMPLETE |
| 669 | 667 |
| OLD | NEW |