Source code

Revision control

Copy as Markdown

Other Tools

Test Info:

<!DOCTYPE html>
<title>IDBCursor.continue() - index - attempt to pass a key parameter that is not a valid key</title>
<link rel="author" title="Microsoft" href="">
<link rel=assert title="If the key parameter is specified and fulfills any of these conditions this method must throw a DOMException of type DataError">
<link rel=assert title="The parameter is not a valid key.">
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<script src="resources/support.js"></script>
var db,
t = async_test(),
records = [ { pKey: "primaryKey_0", iKey: "indexKey_0" },
{ pKey: "primaryKey_1", iKey: "indexKey_1" } ];
var open_rq = createdb(t);
open_rq.onupgradeneeded = function(e) {
db =;
var objStore = db.createObjectStore("test", {keyPath:"pKey"});
objStore.createIndex("index", "iKey");
for(var i = 0; i < records.length; i++)
open_rq.onsuccess = function(e) {
var cursor_rq = db.transaction("test", "readonly", {durability: 'relaxed'})
cursor_rq.onsuccess = t.step_func(function(e) {
var cursor =;
function() { cursor.continue(document); });
assert_true(cursor instanceof IDBCursorWithValue, "cursor");
<div id="log"></div>