| Index: chrome/test/data/indexeddb/object_store_test.js
|
| diff --git a/chrome/test/data/indexeddb/object_store_test.js b/chrome/test/data/indexeddb/object_store_test.js
|
| index c4a11579fc21b22a4f630e84de9216a57deeee47..7946c9a1fba3dca7d59be03671eeb835064e00b1 100644
|
| --- a/chrome/test/data/indexeddb/object_store_test.js
|
| +++ b/chrome/test/data/indexeddb/object_store_test.js
|
| @@ -40,15 +40,26 @@ function getSuccess()
|
| result.onerror = unexpectedErrorCallback;
|
| }
|
|
|
| -function dataAddedSuccess()
|
| +function addWithSameKeyFailed()
|
| {
|
| - debug('Data added');
|
| + debug('Adding a record with same key failed');
|
| + shouldBe("event.code", "webkitIDBDatabaseException.CONSTRAINT_ERR");
|
|
|
| var result = objectStore.get(1);
|
| result.onsuccess = getSuccess;
|
| result.onerror = unexpectedErrorCallback;
|
| }
|
|
|
| +function dataAddedSuccess()
|
| +{
|
| + debug('Data added');
|
| +
|
| + debug('Try to add employee with same id');
|
| + var result = objectStore.add({fname: "Tom", lname: "Jones", id: 1});
|
| + result.onsuccess = unexpectedSuccessCallback;
|
| + result.onerror = addWithSameKeyFailed;
|
| +}
|
| +
|
| function populateObjectStore()
|
| {
|
| debug('Populating object store');
|
|
|