| Test IndexedDB's KeyRange. |
| |
| On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE". |
| |
| |
| indexedDB = self.indexedDB || self.webkitIndexedDB || self.mozIndexedDB || self.msIndexedDB || self.OIndexedDB; |
| |
| PASS 'lower' in IDBKeyRange is false |
| PASS 'upper' in IDBKeyRange is false |
| PASS 'lowerOpen' in IDBKeyRange is false |
| PASS 'upperOpen' in IDBKeyRange is false |
| PASS 'includes' in IDBKeyRange is false |
| PASS 'only' in IDBKeyRange is true |
| PASS 'lowerBound' in IDBKeyRange is true |
| PASS 'upperBound' in IDBKeyRange is true |
| PASS 'bound' in IDBKeyRange is true |
| |
| instance = IDBKeyRange.only(1) |
| PASS 'lower' in instance is true |
| PASS 'upper' in instance is true |
| PASS 'lowerOpen' in instance is true |
| PASS 'upperOpen' in instance is true |
| PASS 'includes' in instance is true |
| PASS 'only' in instance is false |
| PASS 'lowerBound' in instance is false |
| PASS 'upperBound' in instance is false |
| PASS 'bound' in instance is false |
| |
| IDBKeyRange.only(1) |
| PASS keyRange.lower is 1 |
| PASS keyRange.upper is 1 |
| PASS keyRange.lowerOpen is false |
| PASS keyRange.upperOpen is false |
| PASS keyRange.includes(1.1) is false |
| PASS keyRange.includes(0.9) is false |
| PASS keyRange.includes(1) is true |
| IDBKeyRange.only(3.14) |
| PASS keyRange.lower is 3.14 |
| PASS keyRange.upper is 3.14 |
| PASS keyRange.lowerOpen is false |
| PASS keyRange.upperOpen is false |
| PASS keyRange.includes(3.24) is false |
| PASS keyRange.includes(3.04) is false |
| PASS keyRange.includes(3.14) is true |
| IDBKeyRange.only('a') |
| PASS keyRange.lower is 'a' |
| PASS keyRange.upper is 'a' |
| PASS keyRange.lowerOpen is false |
| PASS keyRange.upperOpen is false |
| PASS keyRange.includes('aa') is false |
| PASS keyRange.includes('') is false |
| PASS keyRange.includes('a') is true |
| IDBKeyRange.lowerBound(10,true) |
| PASS keyRange.lower is 10 |
| PASS keyRange.lowerOpen is true |
| PASS keyRange.upper is undefined. |
| PASS keyRange.upperOpen is true |
| PASS keyRange.includes(10) is false |
| PASS keyRange.includes(10.1) is true |
| PASS keyRange.includes(9.9) is false |
| IDBKeyRange.lowerBound(11,false) |
| PASS keyRange.lower is 11 |
| PASS keyRange.lowerOpen is false |
| PASS keyRange.upper is undefined. |
| PASS keyRange.upperOpen is true |
| PASS keyRange.includes(11) is true |
| PASS keyRange.includes(11.1) is true |
| PASS keyRange.includes(10.9) is false |
| IDBKeyRange.lowerBound(12,undefined) |
| PASS keyRange.lower is 12 |
| PASS keyRange.lowerOpen is false |
| PASS keyRange.upper is undefined. |
| PASS keyRange.upperOpen is true |
| PASS keyRange.includes(12) is true |
| PASS keyRange.includes(12.1) is true |
| PASS keyRange.includes(11.9) is false |
| IDBKeyRange.lowerBound(10.1,true) |
| PASS keyRange.lower is 10.1 |
| PASS keyRange.lowerOpen is true |
| PASS keyRange.upper is undefined. |
| PASS keyRange.upperOpen is true |
| PASS keyRange.includes(10.1) is false |
| PASS keyRange.includes(10.2) is true |
| PASS keyRange.includes(10) is false |
| IDBKeyRange.lowerBound(11.2,false) |
| PASS keyRange.lower is 11.2 |
| PASS keyRange.lowerOpen is false |
| PASS keyRange.upper is undefined. |
| PASS keyRange.upperOpen is true |
| PASS keyRange.includes(11.2) is true |
| PASS keyRange.includes(11.299999999999999) is true |
| PASS keyRange.includes(11.1) is false |
| IDBKeyRange.lowerBound(12.3,undefined) |
| PASS keyRange.lower is 12.3 |
| PASS keyRange.lowerOpen is false |
| PASS keyRange.upper is undefined. |
| PASS keyRange.upperOpen is true |
| PASS keyRange.includes(12.3) is true |
| PASS keyRange.includes(12.4) is true |
| PASS keyRange.includes(12.200000000000001) is false |
| IDBKeyRange.lowerBound('aa',true) |
| PASS keyRange.lower is 'aa' |
| PASS keyRange.lowerOpen is true |
| PASS keyRange.upper is undefined. |
| PASS keyRange.upperOpen is true |
| PASS keyRange.includes('aa') is false |
| PASS keyRange.includes('aaa') is true |
| PASS keyRange.includes('a') is false |
| IDBKeyRange.lowerBound('ab',false) |
| PASS keyRange.lower is 'ab' |
| PASS keyRange.lowerOpen is false |
| PASS keyRange.upper is undefined. |
| PASS keyRange.upperOpen is true |
| PASS keyRange.includes('ab') is true |
| PASS keyRange.includes('abb') is true |
| PASS keyRange.includes('a') is false |
| IDBKeyRange.lowerBound('ac',undefined) |
| PASS keyRange.lower is 'ac' |
| PASS keyRange.lowerOpen is false |
| PASS keyRange.upper is undefined. |
| PASS keyRange.upperOpen is true |
| PASS keyRange.includes('ac') is true |
| PASS keyRange.includes('acc') is true |
| PASS keyRange.includes('a') is false |
| IDBKeyRange.upperBound(20,true) |
| PASS keyRange.upper is 20 |
| PASS keyRange.upperOpen is true |
| PASS keyRange.lower is undefined. |
| PASS keyRange.lowerOpen is true |
| PASS keyRange.includes(20) is false |
| PASS keyRange.includes(20.1) is false |
| PASS keyRange.includes(19.9) is true |
| IDBKeyRange.upperBound(21,false) |
| PASS keyRange.upper is 21 |
| PASS keyRange.upperOpen is false |
| PASS keyRange.lower is undefined. |
| PASS keyRange.lowerOpen is true |
| PASS keyRange.includes(21) is true |
| PASS keyRange.includes(21.1) is false |
| PASS keyRange.includes(20.9) is true |
| IDBKeyRange.upperBound(22,undefined) |
| PASS keyRange.upper is 22 |
| PASS keyRange.upperOpen is false |
| PASS keyRange.lower is undefined. |
| PASS keyRange.lowerOpen is true |
| PASS keyRange.includes(22) is true |
| PASS keyRange.includes(22.1) is false |
| PASS keyRange.includes(21.9) is true |
| IDBKeyRange.upperBound(20.2,true) |
| PASS keyRange.upper is 20.2 |
| PASS keyRange.upperOpen is true |
| PASS keyRange.lower is undefined. |
| PASS keyRange.lowerOpen is true |
| PASS keyRange.includes(20.2) is false |
| PASS keyRange.includes(20.3) is false |
| PASS keyRange.includes(20.099999999999998) is true |
| IDBKeyRange.upperBound(21.3,false) |
| PASS keyRange.upper is 21.3 |
| PASS keyRange.upperOpen is false |
| PASS keyRange.lower is undefined. |
| PASS keyRange.lowerOpen is true |
| PASS keyRange.includes(21.3) is true |
| PASS keyRange.includes(21.400000000000002) is false |
| PASS keyRange.includes(21.2) is true |
| IDBKeyRange.upperBound(22.4,undefined) |
| PASS keyRange.upper is 22.4 |
| PASS keyRange.upperOpen is false |
| PASS keyRange.lower is undefined. |
| PASS keyRange.lowerOpen is true |
| PASS keyRange.includes(22.4) is true |
| PASS keyRange.includes(22.5) is false |
| PASS keyRange.includes(22.299999999999997) is true |
| IDBKeyRange.upperBound('ba',true) |
| PASS keyRange.upper is 'ba' |
| PASS keyRange.upperOpen is true |
| PASS keyRange.lower is undefined. |
| PASS keyRange.lowerOpen is true |
| PASS keyRange.includes('ba') is false |
| PASS keyRange.includes('baa') is false |
| PASS keyRange.includes('b') is true |
| IDBKeyRange.upperBound('bb',false) |
| PASS keyRange.upper is 'bb' |
| PASS keyRange.upperOpen is false |
| PASS keyRange.lower is undefined. |
| PASS keyRange.lowerOpen is true |
| PASS keyRange.includes('bb') is true |
| PASS keyRange.includes('bbb') is false |
| PASS keyRange.includes('b') is true |
| IDBKeyRange.upperBound('bc',undefined) |
| PASS keyRange.upper is 'bc' |
| PASS keyRange.upperOpen is false |
| PASS keyRange.lower is undefined. |
| PASS keyRange.lowerOpen is true |
| PASS keyRange.includes('bc') is true |
| PASS keyRange.includes('bcc') is false |
| PASS keyRange.includes('b') is true |
| IDBKeyRange.bound(30,40, undefined, undefined) |
| PASS keyRange.lower is 30 |
| PASS keyRange.upper is 40 |
| PASS keyRange.lowerOpen is false |
| PASS keyRange.upperOpen is false |
| PASS keyRange.includes(30) is true |
| PASS keyRange.includes(40) is true |
| IDBKeyRange.bound(31,41, false, false) |
| PASS keyRange.lower is 31 |
| PASS keyRange.upper is 41 |
| PASS keyRange.lowerOpen is false |
| PASS keyRange.upperOpen is false |
| PASS keyRange.includes(31) is true |
| PASS keyRange.includes(41) is true |
| IDBKeyRange.bound(32,42, false, true) |
| PASS keyRange.lower is 32 |
| PASS keyRange.upper is 42 |
| PASS keyRange.lowerOpen is false |
| PASS keyRange.upperOpen is true |
| PASS keyRange.includes(32) is true |
| PASS keyRange.includes(42) is false |
| IDBKeyRange.bound(33,43, true, false) |
| PASS keyRange.lower is 33 |
| PASS keyRange.upper is 43 |
| PASS keyRange.lowerOpen is true |
| PASS keyRange.upperOpen is false |
| PASS keyRange.includes(33) is false |
| PASS keyRange.includes(43) is true |
| IDBKeyRange.bound(34,44, true, true) |
| PASS keyRange.lower is 34 |
| PASS keyRange.upper is 44 |
| PASS keyRange.lowerOpen is true |
| PASS keyRange.upperOpen is true |
| PASS keyRange.includes(34) is false |
| PASS keyRange.includes(44) is false |
| IDBKeyRange.bound(30.1,40.2, undefined, undefined) |
| PASS keyRange.lower is 30.1 |
| PASS keyRange.upper is 40.2 |
| PASS keyRange.lowerOpen is false |
| PASS keyRange.upperOpen is false |
| PASS keyRange.includes(30.1) is true |
| PASS keyRange.includes(40.2) is true |
| IDBKeyRange.bound(31.3,41.4, false, false) |
| PASS keyRange.lower is 31.3 |
| PASS keyRange.upper is 41.4 |
| PASS keyRange.lowerOpen is false |
| PASS keyRange.upperOpen is false |
| PASS keyRange.includes(31.3) is true |
| PASS keyRange.includes(41.4) is true |
| IDBKeyRange.bound(32.5,42.6, false, true) |
| PASS keyRange.lower is 32.5 |
| PASS keyRange.upper is 42.6 |
| PASS keyRange.lowerOpen is false |
| PASS keyRange.upperOpen is true |
| PASS keyRange.includes(32.5) is true |
| PASS keyRange.includes(42.6) is false |
| IDBKeyRange.bound(33.7,43.8, true, false) |
| PASS keyRange.lower is 33.7 |
| PASS keyRange.upper is 43.8 |
| PASS keyRange.lowerOpen is true |
| PASS keyRange.upperOpen is false |
| PASS keyRange.includes(33.7) is false |
| PASS keyRange.includes(43.8) is true |
| IDBKeyRange.bound(34.9,44, true, true) |
| PASS keyRange.lower is 34.9 |
| PASS keyRange.upper is 44 |
| PASS keyRange.lowerOpen is true |
| PASS keyRange.upperOpen is true |
| PASS keyRange.includes(34.9) is false |
| PASS keyRange.includes(44) is false |
| IDBKeyRange.bound('aaa','aba', false, false) |
| PASS keyRange.lower is 'aaa' |
| PASS keyRange.upper is 'aba' |
| PASS keyRange.lowerOpen is false |
| PASS keyRange.upperOpen is false |
| PASS keyRange.includes('aaa') is true |
| PASS keyRange.includes('aba') is true |
| IDBKeyRange.bound('aab','abb', undefined, undefined) |
| PASS keyRange.lower is 'aab' |
| PASS keyRange.upper is 'abb' |
| PASS keyRange.lowerOpen is false |
| PASS keyRange.upperOpen is false |
| PASS keyRange.includes('aab') is true |
| PASS keyRange.includes('abb') is true |
| IDBKeyRange.bound('aac','abc', false, false) |
| PASS keyRange.lower is 'aac' |
| PASS keyRange.upper is 'abc' |
| PASS keyRange.lowerOpen is false |
| PASS keyRange.upperOpen is false |
| PASS keyRange.includes('aac') is true |
| PASS keyRange.includes('abc') is true |
| IDBKeyRange.bound('aad','abd', false, true) |
| PASS keyRange.lower is 'aad' |
| PASS keyRange.upper is 'abd' |
| PASS keyRange.lowerOpen is false |
| PASS keyRange.upperOpen is true |
| PASS keyRange.includes('aad') is true |
| PASS keyRange.includes('abd') is false |
| IDBKeyRange.bound('aae','abe', true, false) |
| PASS keyRange.lower is 'aae' |
| PASS keyRange.upper is 'abe' |
| PASS keyRange.lowerOpen is true |
| PASS keyRange.upperOpen is false |
| PASS keyRange.includes('aae') is false |
| PASS keyRange.includes('abe') is true |
| IDBKeyRange.bound('aaf','abf', true, true) |
| PASS keyRange.lower is 'aaf' |
| PASS keyRange.upper is 'abf' |
| PASS keyRange.lowerOpen is true |
| PASS keyRange.upperOpen is true |
| PASS keyRange.includes('aaf') is false |
| PASS keyRange.includes('abf') is false |
| Passing an invalid key into only({}) |
| Expecting exception from IDBKeyRange.only({}) |
| PASS Exception was thrown. |
| PASS code is 0 |
| PASS ename is 'DataError' |
| Exception message: Provided data is inadequate. |
| Passing an invalid key into upperBound({}) |
| Expecting exception from IDBKeyRange.upperBound({}) |
| PASS Exception was thrown. |
| PASS code is 0 |
| PASS ename is 'DataError' |
| Exception message: Provided data is inadequate. |
| Passing an invalid key into lowerBound({}) |
| Expecting exception from IDBKeyRange.lowerBound({}) |
| PASS Exception was thrown. |
| PASS code is 0 |
| PASS ename is 'DataError' |
| Exception message: Provided data is inadequate. |
| Passing an invalid key into bound(null, {}) |
| Expecting exception from IDBKeyRange.bound(null, {}) |
| PASS Exception was thrown. |
| PASS code is 0 |
| PASS ename is 'DataError' |
| Exception message: Provided data is inadequate. |
| Passing an invalid key into bound({},null) |
| Expecting exception from IDBKeyRange.bound({}, null) |
| PASS Exception was thrown. |
| PASS code is 0 |
| PASS ename is 'DataError' |
| Exception message: Provided data is inadequate. |
| Passing an invalid key into bound({}, {}) |
| Expecting exception from IDBKeyRange.bound({}, {}) |
| PASS Exception was thrown. |
| PASS code is 0 |
| PASS ename is 'DataError' |
| Exception message: Provided data is inadequate. |
| Lower key greater than higher key, bound(4, 3) |
| Expecting exception from IDBKeyRange.bound(4, 3) |
| PASS Exception was thrown. |
| PASS code is 0 |
| PASS ename is 'DataError' |
| Exception message: Provided data is inadequate. |
| Equal keys, either of the bounds is open, bound(4, 4, true, false) |
| Expecting exception from IDBKeyRange.bound(4, 4, true, false) |
| PASS Exception was thrown. |
| PASS code is 0 |
| PASS ename is 'DataError' |
| Exception message: Provided data is inadequate. |
| Equal keys, either of the bounds is open, bound(4, 4, false, true) |
| Expecting exception from IDBKeyRange.bound(4, 4, false, true) |
| PASS Exception was thrown. |
| PASS code is 0 |
| PASS ename is 'DataError' |
| Exception message: Provided data is inadequate. |
| Equal keys, either of the bounds is open, bound(4, 4, true, true) |
| Expecting exception from IDBKeyRange.bound(4, 4, true, true) |
| PASS Exception was thrown. |
| PASS code is 0 |
| PASS ename is 'DataError' |
| Exception message: Provided data is inadequate. |
| Equal keys, none of the bounds is open, bound(4, 4, false, false) |
| Passing an invalid key in to IDBKeyRange.includes({}) |
| Expecting exception from invalidKeyKeyRange.includes({}) |
| PASS Exception was thrown. |
| PASS code is 0 |
| PASS ename is 'DataError' |
| Exception message: Failed to execute 'includes' on 'IDBKeyRange': The passed-in value is not a valid IndexedDB key. |
| PASS successfullyParsed is true |
| |
| TEST COMPLETE |
| |