diff options
author | Aaron <aaron@10gen.com> | 2009-02-20 12:24:20 -0500 |
---|---|---|
committer | Aaron <aaron@10gen.com> | 2009-02-20 12:24:20 -0500 |
commit | 7d0d3c52936cf04e0645f09d4b72dc03f5ef9862 (patch) | |
tree | 0a42f8e85c857f4e5f056201665493a9cbe70e22 /jstests/_runner_leak_nojni.js | |
parent | cf2a7284d18231af6e58f75b3849ecd43b99a30d (diff) | |
download | mongo-7d0d3c52936cf04e0645f09d4b72dc03f5ef9862.tar.gz |
Issue meminfo cmd from dummy db
Diffstat (limited to 'jstests/_runner_leak_nojni.js')
-rw-r--r-- | jstests/_runner_leak_nojni.js | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/jstests/_runner_leak_nojni.js b/jstests/_runner_leak_nojni.js index 97f61cf8e13..fe2c6b23902 100644 --- a/jstests/_runner_leak_nojni.js +++ b/jstests/_runner_leak_nojni.js @@ -3,8 +3,10 @@ // var files = listFiles("jstests"); -db.getSisterDB( "admin" ).runCommand( "closeAllDatabases" ); -prev = db.runCommand( "meminfo" ); +var dummyDb = db.getSisterDB( "dummyDBdummydummy" ); + +dummyDb.getSisterDB( "admin" ).runCommand( "closeAllDatabases" ); +prev = dummyDb.runCommand( "meminfo" ); print( "START : " + tojson( prev ) ); @@ -26,8 +28,8 @@ files.forEach( print(" Test : " + x.name + " ..."); print(" " + Date.timeFunc( function() { load(x.name); }, 1) + "ms"); - assert( db.getSisterDB( "admin" ).runCommand( "closeAllDatabases" ).ok == 1 , "closeAllDatabases failed" ); - var now = db.runCommand( "meminfo" ); + assert( dummyDb.getSisterDB( "admin" ).runCommand( "closeAllDatabases" ).ok == 1 , "closeAllDatabases failed" ); + var now = dummyDb.runCommand( "meminfo" ); if ( now.virtual > prev.virtual ) print( " LEAK : " + prev.virtual + " -->> " + now.virtual ); prev = now; @@ -36,5 +38,5 @@ files.forEach( -db.getSisterDB( "admin" ).runCommand( "closeAllDatabases" ); -print( "END : " + tojson( db.runCommand( "meminfo" ) ) ); +dummyDb.getSisterDB( "admin" ).runCommand( "closeAllDatabases" ); +print( "END : " + tojson( dummyDb.runCommand( "meminfo" ) ) ); |