summaryrefslogtreecommitdiffstats
path: root/LayoutTests/storage/indexeddb/keyrange.html
diff options
context:
space:
mode:
Diffstat (limited to 'LayoutTests/storage/indexeddb/keyrange.html')
-rw-r--r--LayoutTests/storage/indexeddb/keyrange.html47
1 files changed, 47 insertions, 0 deletions
diff --git a/LayoutTests/storage/indexeddb/keyrange.html b/LayoutTests/storage/indexeddb/keyrange.html
index c3885fc..48708d9 100644
--- a/LayoutTests/storage/indexeddb/keyrange.html
+++ b/LayoutTests/storage/indexeddb/keyrange.html
@@ -112,6 +112,53 @@ function test()
checkBoundKeyRange("'aae'", "'abe'", true, false);
checkBoundKeyRange("'aaf'", "'abf'", true, true);
+ try {
+ debug("Passing an invalid key into only([])");
+ webkitIDBKeyRange.only([]);
+ testFailed("No exception thrown");
+ } catch (e) {
+ testPassed("Caught exception: " + e.toString());
+ }
+
+ try {
+ debug("Passing an invalid key into rightBound([])");
+ webkitIDBKeyRange.rightBound([]);
+ testFailed("No exception thrown");
+ } catch (e) {
+ testPassed("Caught exception: " + e.toString());
+ }
+
+ try {
+ debug("Passing an invalid key into leftBound([])");
+ webkitIDBKeyRange.leftBound([]);
+ testFailed("No exception thrown");
+ } catch (e) {
+ testPassed("Caught exception: " + e.toString());
+ }
+
+ try {
+ debug("Passing an invalid key into bound(null, [])");
+ webkitIDBKeyRange.bound(null, []);
+ testFailed("No exception thrown");
+ } catch (e) {
+ testPassed("Caught exception: " + e.toString());
+ }
+
+ try {
+ debug("Passing an invalid key into bound([],null)");
+ webkitIDBKeyRange.bound([], null);
+ testFailed("No exception thrown");
+ } catch (e) {
+ testPassed("Caught exception: " + e.toString());
+ }
+
+ try {
+ debug("Passing an invalid key into bound([], [])");
+ webkitIDBKeyRange.bound([], []);
+ testFailed("No exception thrown");
+ } catch (e) {
+ testPassed("Caught exception: " + e.toString());
+ }
}
test();