Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Adjust times on geo_near_random tests

  • Loading branch information...
commit fe341ea9e06d7103cf4efbdaf30844582b02bcb5 1 parent b5e57ba
Mathias Stearn authored September 03, 2010
2  jstests/geo_near_random1.js
@@ -3,7 +3,7 @@ load("jstests/libs/geo_near_random.js");
3 3
 
4 4
 var test = new GeoNearRandomTest("geo_near_random1");
5 5
 
6  
-test.insertPts(100);
  6
+test.insertPts(50);
7 7
 
8 8
 test.testPt([0,0]);
9 9
 test.testPt(test.mkPt());
2  jstests/slowNightly/geo_near_random1.js
@@ -3,7 +3,7 @@ load("jstests/libs/geo_near_random.js");
3 3
 
4 4
 var test = new GeoNearRandomTest("nightly.geo_near_random1");
5 5
 
6  
-test.insertPts(1000);
  6
+test.insertPts(200);
7 7
 
8 8
 test.testPt([0,0]);
9 9
 test.testPt(test.mkPt());
2  jstests/slowNightly/geo_near_random2.js
@@ -3,7 +3,7 @@ load("jstests/libs/geo_near_random.js");
3 3
 
4 4
 var test = new GeoNearRandomTest("nightly.geo_near_random2");
5 5
 
6  
-test.insertPts(100000);
  6
+test.insertPts(10000);
7 7
 
8 8
 opts = {sphere:0, nToTest:test.nPts*0.01}; 
9 9
 test.testPt([0,0], opts);
13  jstests/slowWeekly/geo_near_random1.js
... ...
@@ -0,0 +1,13 @@
  1
+// this tests all points using $near
  2
+load("jstests/libs/geo_near_random.js");
  3
+
  4
+var test = new GeoNearRandomTest("weekly.geo_near_random1");
  5
+
  6
+test.insertPts(1000);
  7
+
  8
+test.testPt([0,0]);
  9
+test.testPt(test.mkPt());
  10
+test.testPt(test.mkPt());
  11
+test.testPt(test.mkPt());
  12
+test.testPt(test.mkPt());
  13
+
21  jstests/slowWeekly/geo_near_random2.js
... ...
@@ -0,0 +1,21 @@
  1
+// this tests 1% of all points using $near and $nearSphere
  2
+load("jstests/libs/geo_near_random.js");
  3
+
  4
+var test = new GeoNearRandomTest("weekly.geo_near_random2");
  5
+
  6
+test.insertPts(50000);
  7
+
  8
+opts = {sphere:0, nToTest:test.nPts*0.01}; 
  9
+test.testPt([0,0], opts);
  10
+test.testPt(test.mkPt(), opts);
  11
+test.testPt(test.mkPt(), opts);
  12
+test.testPt(test.mkPt(), opts);
  13
+test.testPt(test.mkPt(), opts);
  14
+
  15
+opts.sphere = 1
  16
+test.testPt([0,0], opts);
  17
+test.testPt(test.mkPt(0.8), opts);
  18
+test.testPt(test.mkPt(0.8), opts);
  19
+test.testPt(test.mkPt(0.8), opts);
  20
+test.testPt(test.mkPt(0.8), opts);
  21
+

0 notes on commit fe341ea

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