chromium/third_party/blink/web_tests/storage/indexeddb/mozilla/create-index-with-integer-keys-expected.txt

Test IndexedDB's creating index with integer keys

On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".

dbname = "create-index-with-integer-keys.html"
indexedDB.deleteDatabase(dbname)
indexedDB.open(dbname)
objectStore = db.createObjectStore('foo', { keyPath: 'id' });
data = { id: 16, num: 42 };
objectStore.add(data);
index = objectStore.createIndex('foo', 'num');
result = index.openKeyCursor();
cursor = event.target.result;
PASS cursor == null is false
PASS cursor.key is data.num
PASS cursor.primaryKey is data.id
PASS successfullyParsed is true

TEST COMPLETE