summaryrefslogtreecommitdiff
path: root/jstests/dur
diff options
context:
space:
mode:
authorDan Pasette <dan@10gen.com>2013-01-18 18:00:37 -0500
committerDan Pasette <dan@10gen.com>2013-01-18 18:01:23 -0500
commit0f14e723eacd93bd0fdbafca417285b85837e3bb (patch)
tree7007323f9220c9843b79f27dbc8eaf1dfa251317 /jstests/dur
parent6151edafad14a36f0f49ca5e592f5b81dac58949 (diff)
downloadmongo-0f14e723eacd93bd0fdbafca417285b85837e3bb.tar.gz
disable dur_passthrough.js on 32 bit platforms so builders don't run out of VM.
Diffstat (limited to 'jstests/dur')
-rw-r--r--jstests/dur/dur_passthrough.js61
1 files changed, 36 insertions, 25 deletions
diff --git a/jstests/dur/dur_passthrough.js b/jstests/dur/dur_passthrough.js
index 1840fb72bbf..ce92ba4eba5 100644
--- a/jstests/dur/dur_passthrough.js
+++ b/jstests/dur/dur_passthrough.js
@@ -4,41 +4,52 @@
//TODO(mathias) add --master or make another test
//conn = startMongodEmpty("--port", 30200, "--dbpath", "/data/db/dur_passthrough", "--dur", "--smallfiles", "--durOptions", "24");
-conn = startMongodEmpty("--port", 30200, "--dbpath", "/data/db/dur_passthrough", "--dur", "--smallfiles", "--durOptions", "8");
+
+conn = startMongodEmpty("--port", 30200, "--dbpath", "/data/db/dur_passthrough", "--dur", "--nopreallocj", "--smallfiles",
+"--durOptions", "8");
db = conn.getDB("test");
-var files = listFiles("jstests");
-files = files.sort(compareOn('name'));
+function doTest() {
+ var files = listFiles("jstests");
+ files = files.sort(compareOn('name'));
-var runnerStart = new Date()
+ var runnerStart = new Date()
-files.forEach(
- function (x) {
+ files.forEach(
+ function (x) {
- if (/[\/\\]_/.test(x.name) ||
- !/\.js$/.test(x.name) ||
- /repair/.test(x.name) || // fails on recovery
- /shellkillop/.test(x.name) || // takes forever and don't test anything new
- false // placeholder so all real tests end in ||
- )
- {
- print(" >>>>>>>>>>>>>>> skipping " + x.name);
- return;
- }
+ if (/[\/\\]_/.test(x.name) ||
+ !/\.js$/.test(x.name) ||
+ /repair/.test(x.name) || // fails on recovery
+ /shellkillop/.test(x.name) || // takes forever and don't test anything new
+ false // placeholder so all real tests end in ||
+ )
+ {
+ print(" >>>>>>>>>>>>>>> skipping " + x.name);
+ return;
+ }
- print();
- print(" *******************************************");
- print(" Test : " + x.name + " ...");
- print(" " + Date.timeFunc(function () { load(x.name); }, 1) + "ms");
+ print();
+ print(" *******************************************");
+ print(" Test : " + x.name + " ...");
+ print(" " + Date.timeFunc(function () { load(x.name); }, 1) + "ms");
+
+ }
+ );
- }
-);
+ stopMongod(30200);
-stopMongod(30200);
+ var runnerEnd = new Date()
-var runnerEnd = new Date()
+ print( "total runner time: " + ( ( runnerEnd.getTime() - runnerStart.getTime() ) / 1000 ) + "secs" )
+}
-print( "total runner time: " + ( ( runnerEnd.getTime() - runnerStart.getTime() ) / 1000 ) + "secs" )
+if (db.serverBuildInfo().bits == 32) {
+ print("build is 32 bits -- skipping test")
+}
+else {
+ doTest();
+}
//TODO(mathias): test recovery here