1 Test IndexedDB readonly properties
3 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
6 dbname = "readonly.html"
7 indexedDB.deleteDatabase(dbname)
9 transaction = event.target.transaction;
10 trying to set readonly property transaction.mode
11 transaction.mode = 666
12 PASS transaction.mode is still versionchange
13 trying to set readonly property transaction.db
15 PASS transaction.db is still [object IDBDatabase]
16 Deleted all object stores.
17 objectStore = db.createObjectStore('foo');
18 trying to set readonly property objectStore.name
19 objectStore.name = 'bar'
20 PASS objectStore.name is still foo
21 trying to set readonly property objectStore.keyPath
22 objectStore.keyPath = 'bar'
23 PASS objectStore.keyPath is still null
24 result = objectStore.add({}, 'first');
25 result = objectStore.openCursor();
26 cursor = event.target.result;
27 trying to set readonly property cursor.source
29 PASS cursor.source is still [object IDBObjectStore]
30 trying to set readonly property cursor.direction
31 cursor.direction = 666
32 PASS cursor.direction is still next
33 trying to set readonly property cursor.key
35 PASS cursor.key is still first
36 trying to set readonly property cursor.primaryKey
37 cursor.primaryKey = Infinity
38 PASS cursor.primaryKey is still first
39 index = objectStore.createIndex('first', 'first');
40 trying to set readonly property index.name
42 PASS index.name is still first
43 trying to set readonly property index.objectStore
44 index.objectStore = this
45 PASS index.objectStore is still [object IDBObjectStore]
46 trying to set readonly property index.keyPath
48 PASS index.keyPath is still first
49 trying to set readonly property index.unique
51 PASS index.unique is still false
52 trying to set readonly property keyRange.lower
53 keyRange.lower = Infinity
54 PASS keyRange.lower is still first
55 trying to set readonly property keyRange.upper
56 keyRange.upper = Infinity
57 PASS keyRange.upper is still first
58 trying to set readonly property keyRange.lowerOpen
59 keyRange.lowerOpen = true
60 PASS keyRange.lowerOpen is still false
61 trying to set readonly property keyRange.upperOpen
62 keyRange.upperOpen = true
63 PASS keyRange.upperOpen is still false
64 trying to set readonly property request.result
65 request.result = Infinity
66 PASS request.result is still [object IDBDatabase]
67 trying to set readonly property request.error
69 PASS request.error is still null
70 trying to set readonly property request.source
72 PASS request.source is still null
73 trying to set readonly property request.transaction
74 request.transaction = this
75 PASS request.transaction is still null
76 trying to set readonly property request.readyState
77 request.readyState = 666
78 PASS request.readyState is still done
79 db = event.target.result
80 trying to set readonly property db.name
82 PASS db.name is still readonly.html
83 PASS successfullyParsed is true