2011-05-12 David Grogan <dgrogan@chromium.org>

        Reviewed by Nate Chapin.

        IndexedDB: fix up database-quota.html layout test
        https://bugs.webkit.org/show_bug.cgi?id=60519

        Remove commitAndContinue idiom; translate some missed instances of
        event.code to event.target.errorCode from bug 54331

        * storage/indexeddb/database-quota-expected.txt:
        * storage/indexeddb/database-quota.html:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@86363 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent 0d3fbb94
2011-05-12 David Grogan <dgrogan@chromium.org>
Reviewed by Nate Chapin.
IndexedDB: fix up database-quota.html layout test
https://bugs.webkit.org/show_bug.cgi?id=60519
Remove commitAndContinue idiom; translate some missed instances of
event.code to event.target.errorCode from bug 54331
* storage/indexeddb/database-quota-expected.txt:
* storage/indexeddb/database-quota.html:
2011-05-12 Ryosuke Niwa <rniwa@webkit.org>
Reviewed by Darin Adler.
......@@ -25,7 +25,7 @@ trans = db.transaction([], webkitIDBTransaction.READ_WRITE)
Creating 'data' which contains 64K of data
PASS data.length is 65536
store = trans.objectStore('test123')
Error function called: (undefined) undefined
Error function called: (13) The transaction was aborted, so the request cannot be fulfilled.
event.preventDefault()
PASS Adding data failed due to quota error. Data added was about 5 MB
PASS successfullyParsed is true
......
......@@ -36,6 +36,7 @@ function setVersionSuccess()
window.trans = evalAndLog("trans = event.target.result");
shouldBeTrue("trans !== null");
trans.onabort = unexpectedAbortCallback;
trans.oncomplete = checkQuotaEnforcing;
deleteAllObjectStores(db);
......@@ -47,7 +48,6 @@ function setVersionSuccess()
objectStore = evalAndLog('db.createObjectStore("test123")');
checkObjectStore();
commitAndContinue();
}
function checkObjectStore()
......@@ -59,11 +59,6 @@ function checkObjectStore()
shouldBe("db.objectStoreNames.contains('test123')", "true");
}
function commitAndContinue()
{
window.setTimeout(checkQuotaEnforcing, 0);
}
function checkQuotaEnforcing()
{
var trans = evalAndLog("trans = db.transaction([], webkitIDBTransaction.READ_WRITE)");
......@@ -97,7 +92,7 @@ function addData()
function logError()
{
debug("Error function called: (" + event.code + ") " + event.message);
debug("Error function called: (" + event.target.errorCode + ") " + event.target.webkitErrorMessage);
evalAndLog("event.preventDefault()");
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment