summaryrefslogtreecommitdiff
path: root/jstests/or6.js
diff options
context:
space:
mode:
authorAaron <aaron@10gen.com>2010-09-14 14:29:58 -0700
committerAaron <aaron@10gen.com>2010-09-14 14:30:18 -0700
commit57c2cf9b0138e2a6e1f5a51506778b2822deadce (patch)
tree5384b54e8b8acf7168f12543b91e3c528d50a4a2 /jstests/or6.js
parent5361ed8b1d7cbfec0044a7f9f3e8c25ffcd6977a (diff)
downloadmongo-57c2cf9b0138e2a6e1f5a51506778b2822deadce.tar.gz
SERVER-1213 allow splitting of or ranges
Diffstat (limited to 'jstests/or6.js')
-rw-r--r--jstests/or6.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/jstests/or6.js b/jstests/or6.js
index 3800c7874e6..e73fbdef885 100644
--- a/jstests/or6.js
+++ b/jstests/or6.js
@@ -7,8 +7,8 @@ assert.eq.automsg( "2", "t.find( {$or:[{a:{$gt:2}},{a:{$gt:0}}]} ).explain().cla
assert.eq.automsg( "2", "t.find( {$or:[{a:{$lt:2}},{a:{$lt:4}}]} ).explain().clauses[ 1 ].indexBounds.a[ 0 ][ 0 ]" );
assert.eq.automsg( "2", "t.find( {$or:[{a:{$gt:2,$lt:10}},{a:{$gt:0,$lt:5}}]} ).explain().clauses[ 1 ].indexBounds.a[ 0 ][ 1 ]" );
-assert.eq.automsg( "0", "t.find( {$or:[{a:{$gt:2,$lt:10}},{a:{$gt:0,$lt:15}}]} ).explain().clauses[ 1 ].indexBounds.a[ 0 ][ 0 ]" );
-assert.eq.automsg( "15", "t.find( {$or:[{a:{$gt:2,$lt:10}},{a:{$gt:0,$lt:15}}]} ).explain().clauses[ 1 ].indexBounds.a[ 0 ][ 1 ]" );
+
+assert.eq( [ [ 0, 2 ], [ 10, 15 ] ], t.find( {$or:[{a:{$gt:2,$lt:10}},{a:{$gt:0,$lt:15}}]} ).explain().clauses[ 1 ].indexBounds.a );
// no separate clauses
assert.eq.automsg( "null", "t.find( {$or:[{a:{$gt:2,$lt:10}},{a:{$gt:3,$lt:5}}]} ).explain().clauses" );
@@ -28,4 +28,4 @@ t.ensureIndex( {a:1,b:1} );
assert.eq.automsg( "2", "t.find( {$or:[{a:{$in:[1,2]},b:5}, {a:2,b:6}]} ).explain().clauses.length" );
assert.eq.automsg( "2", "t.find( {$or:[{a:{$gt:1,$lte:2},b:5}, {a:2,b:6}]} ).explain().clauses.length" );
assert.eq.automsg( "2", "t.find( {$or:[{a:{$gt:1,$lte:3},b:5}, {a:2,b:6}]} ).explain().clauses.length" );
-assert.eq.automsg( "null", "t.find( {$or:[{a:{$in:[1,2]}}, {a:2}]} ).explain().clauses" ); \ No newline at end of file
+assert.eq.automsg( "null", "t.find( {$or:[{a:{$in:[1,2]}}, {a:2}]} ).explain().clauses" );