chromium/third_party/blink/web_tests/storage/indexeddb/cursor-overloads-expected.txt

Validate the overloads of IDBObjectStore.openCursor(), IDBIndex.openCursor() and IDBIndex.openKeyCursor().

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

dbname = "cursor-overloads.html"
indexedDB.deleteDatabase(dbname)
indexedDB.open(dbname)
store = db.createObjectStore('store')
index = store.createIndex('index', 'value')
store.put({value: 0}, 0)


verifyOverloads():
trans = db.transaction('store', 'readonly', {durability: 'relaxed'})
store = trans.objectStore('store')
index = store.index('index')
store.openCursor()
PASS event.target.result is non-null.
PASS event.target.result.direction is "next"
store.openCursor(0)
PASS event.target.result is non-null.
PASS event.target.result.direction is "next"
store.openCursor(0, 'next')
PASS event.target.result is non-null.
PASS event.target.result.direction is "next"
store.openCursor(0, 'nextunique')
PASS event.target.result is non-null.
PASS event.target.result.direction is "nextunique"
store.openCursor(0, 'prev')
PASS event.target.result is non-null.
PASS event.target.result.direction is "prev"
store.openCursor(0, 'prevunique')
PASS event.target.result is non-null.
PASS event.target.result.direction is "prevunique"
store.openCursor(IDBKeyRange.only(0))
PASS event.target.result is non-null.
PASS event.target.result.direction is "next"
store.openCursor(IDBKeyRange.only(0), 'next')
PASS event.target.result is non-null.
PASS event.target.result.direction is "next"
store.openCursor(IDBKeyRange.only(0), 'nextunique')
PASS event.target.result is non-null.
PASS event.target.result.direction is "nextunique"
store.openCursor(IDBKeyRange.only(0), 'prev')
PASS event.target.result is non-null.
PASS event.target.result.direction is "prev"
store.openCursor(IDBKeyRange.only(0), 'prevunique')
PASS event.target.result is non-null.
PASS event.target.result.direction is "prevunique"
store.openKeyCursor()
PASS event.target.result is non-null.
PASS event.target.result.direction is "next"
store.openKeyCursor(0)
PASS event.target.result is non-null.
PASS event.target.result.direction is "next"
store.openKeyCursor(0, 'next')
PASS event.target.result is non-null.
PASS event.target.result.direction is "next"
store.openKeyCursor(0, 'nextunique')
PASS event.target.result is non-null.
PASS event.target.result.direction is "nextunique"
store.openKeyCursor(0, 'prev')
PASS event.target.result is non-null.
PASS event.target.result.direction is "prev"
store.openKeyCursor(0, 'prevunique')
PASS event.target.result is non-null.
PASS event.target.result.direction is "prevunique"
store.openKeyCursor(IDBKeyRange.only(0))
PASS event.target.result is non-null.
PASS event.target.result.direction is "next"
store.openKeyCursor(IDBKeyRange.only(0), 'next')
PASS event.target.result is non-null.
PASS event.target.result.direction is "next"
store.openKeyCursor(IDBKeyRange.only(0), 'nextunique')
PASS event.target.result is non-null.
PASS event.target.result.direction is "nextunique"
store.openKeyCursor(IDBKeyRange.only(0), 'prev')
PASS event.target.result is non-null.
PASS event.target.result.direction is "prev"
store.openKeyCursor(IDBKeyRange.only(0), 'prevunique')
PASS event.target.result is non-null.
PASS event.target.result.direction is "prevunique"
index.openCursor()
PASS event.target.result is non-null.
PASS event.target.result.direction is "next"
index.openCursor(0)
PASS event.target.result is non-null.
PASS event.target.result.direction is "next"
index.openCursor(0, 'next')
PASS event.target.result is non-null.
PASS event.target.result.direction is "next"
index.openCursor(0, 'nextunique')
PASS event.target.result is non-null.
PASS event.target.result.direction is "nextunique"
index.openCursor(0, 'prev')
PASS event.target.result is non-null.
PASS event.target.result.direction is "prev"
index.openCursor(0, 'prevunique')
PASS event.target.result is non-null.
PASS event.target.result.direction is "prevunique"
index.openCursor(IDBKeyRange.only(0))
PASS event.target.result is non-null.
PASS event.target.result.direction is "next"
index.openCursor(IDBKeyRange.only(0), 'next')
PASS event.target.result is non-null.
PASS event.target.result.direction is "next"
index.openCursor(IDBKeyRange.only(0), 'nextunique')
PASS event.target.result is non-null.
PASS event.target.result.direction is "nextunique"
index.openCursor(IDBKeyRange.only(0), 'prev')
PASS event.target.result is non-null.
PASS event.target.result.direction is "prev"
index.openCursor(IDBKeyRange.only(0), 'prevunique')
PASS event.target.result is non-null.
PASS event.target.result.direction is "prevunique"
index.openKeyCursor()
PASS event.target.result is non-null.
PASS event.target.result.direction is "next"
index.openKeyCursor(0)
PASS event.target.result is non-null.
PASS event.target.result.direction is "next"
index.openKeyCursor(0, 'next')
PASS event.target.result is non-null.
PASS event.target.result.direction is "next"
index.openKeyCursor(0, 'nextunique')
PASS event.target.result is non-null.
PASS event.target.result.direction is "nextunique"
index.openKeyCursor(0, 'prev')
PASS event.target.result is non-null.
PASS event.target.result.direction is "prev"
index.openKeyCursor(0, 'prevunique')
PASS event.target.result is non-null.
PASS event.target.result.direction is "prevunique"
index.openKeyCursor(IDBKeyRange.only(0))
PASS event.target.result is non-null.
PASS event.target.result.direction is "next"
index.openKeyCursor(IDBKeyRange.only(0), 'next')
PASS event.target.result is non-null.
PASS event.target.result.direction is "next"
index.openKeyCursor(IDBKeyRange.only(0), 'nextunique')
PASS event.target.result is non-null.
PASS event.target.result.direction is "nextunique"
index.openKeyCursor(IDBKeyRange.only(0), 'prev')
PASS event.target.result is non-null.
PASS event.target.result.direction is "prev"
index.openKeyCursor(IDBKeyRange.only(0), 'prevunique')
PASS event.target.result is non-null.
PASS event.target.result.direction is "prevunique"
PASS successfullyParsed is true

TEST COMPLETE