Skip to content
Browse files

another test for good measure MINOR

  • Loading branch information...
1 parent f9e806b commit b5ca7040d8284c8924b0f21863e1d45abf780fe4 @erh erh committed Jun 25, 2009
Showing with 20 additions and 0 deletions.
  1. +20 −0 jstests/cursor1.js
View
20 jstests/cursor1.js
@@ -0,0 +1,20 @@
+
+t = db.cursor1
+t.drop();
+
+big = "";
+while ( big.length < 50000 )
+ big += "asdasdasdasdsdsdadsasdasdasD";
+
+num = Math.ceil( 10000000 / big.length );
+
+for ( var i=0; i<num; i++ ){
+ t.save( { num : i , str : big } );
+}
+
+assert.eq( num , t.find().count() );
+assert.eq( num , t.find().itcount() );
+
+assert.eq( num / 2 , t.find().limit(num/2).itcount() );
+
+t.drop(); // save some space

0 comments on commit b5ca704

Please sign in to comment.
Something went wrong with that request. Please try again.