Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(77)

Unified Diff: third_party/WebKit/LayoutTests/storage/indexeddb/delete-range-count.html

Issue 2433223002: Indexed DB: Remove experimental delete-returns-count change (Closed)
Patch Set: Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/LayoutTests/storage/indexeddb/delete-range-count.html
diff --git a/third_party/WebKit/LayoutTests/storage/indexeddb/delete-range-count.html b/third_party/WebKit/LayoutTests/storage/indexeddb/delete-range-count.html
deleted file mode 100644
index 8c91eafac50be608743eb1f78c3c3269bc9f0281..0000000000000000000000000000000000000000
--- a/third_party/WebKit/LayoutTests/storage/indexeddb/delete-range-count.html
+++ /dev/null
@@ -1,54 +0,0 @@
-<!DOCTYPE html>
-<title>IndexedDB: Delete Range Count Tests</title>
-<script src="../../resources/testharness.js"></script>
-<script src="../../resources/testharnessreport.js"></script>
-<script>
-
-function delete_count(test, description) {
- async_test(function(t) {
- var dbname = location.pathname + ' - ' + description;
- var deleteRequest = indexedDB.deleteDatabase(dbname);
- deleteRequest.onsuccess = t.step_func(function() {
- var openRequest = indexedDB.open(dbname);
- openRequest.onupgradeneeded = t.step_func(function(e) {
- var db = e.target.result;
- var store = db.createObjectStore('store');
- for (var i = 1; i <= 10; ++i) {
- store.put(i, i);
- }
- });
- openRequest.onsuccess = t.step_func(function(e) {
- var db = e.target.result;
- var trans1 = db.transaction('store', 'readwrite');
- var store = trans1.objectStore('store');
- var deleteRequest1 = store.delete(IDBKeyRange.bound(
- test.first.lower,
- test.first.upper));
- deleteRequest1.onsuccess = t.step_func(function(e) {
- var delete_count = e.target.result;
- assert_equals(delete_count, test.first.expected, 'Delete Count');
- var trans2 = db.transaction('store', 'readwrite');
- store = trans2.objectStore('store');
- var deleteRequest2 = store.delete(IDBKeyRange.bound(
- test.second.lower,
- test.second.upper));
- deleteRequest2.onsuccess = t.step_func(function(e) {
- delete_count = e.target.result;
- assert_equals(delete_count, test.second.expected, 'Some records already been deleted');
- t.done();
- });
- });
- });
- openRequest.onerror = t.unreached_func('open failed');
- });
- }, description);
-}
-
-delete_count({ first: { lower: 3, upper: 4, expected: 2},
- second: { lower: 1, upper: 5, expected: 3} },
- 'Delete Range for Overlapping Intervals');
-delete_count({ first: { lower: 3, upper: 8, expected: 6},
- second: { lower: 3, upper: 8, expected: 0} },
- 'Delete Range for Repeated Intervals');
-
-</script>

Powered by Google App Engine
This is Rietveld 408576698