summaryrefslogtreecommitdiff
path: root/jstests/auth/auth1.js
diff options
context:
space:
mode:
authorAaron <aaron@10gen.com>2010-02-01 15:41:04 -0800
committerAaron <aaron@10gen.com>2010-02-01 15:41:04 -0800
commit0131eaf887f0e77941e318ad638273e1260295d2 (patch)
tree1579726aee5c9ac5cdaac813cb947f56f6226974 /jstests/auth/auth1.js
parent53998ac7fc1058ded4eebbb94cba940521446f5e (diff)
downloadmongo-0131eaf887f0e77941e318ad638273e1260295d2.tar.gz
Add debugging support for multiple destructors, and some guards to prevent this condition from arising
Diffstat (limited to 'jstests/auth/auth1.js')
-rw-r--r--jstests/auth/auth1.js16
1 files changed, 8 insertions, 8 deletions
diff --git a/jstests/auth/auth1.js b/jstests/auth/auth1.js
index e549986e96d..d1d46b10b42 100644
--- a/jstests/auth/auth1.js
+++ b/jstests/auth/auth1.js
@@ -3,8 +3,8 @@
port = allocatePorts( 1 )[ 0 ];
baseName = "jstests_auth_auth1";
-//m = startMongod( "--auth", "--port", port, "--dbpath", "/data/db/" + baseName, "--nohttpinterface", "--bind_ip", "127.0.0.1" );
-//db = m.getDB( "test" );
+m = startMongod( "--auth", "--port", port, "--dbpath", "/data/db/" + baseName, "--nohttpinterface", "--bind_ip", "127.0.0.1" );
+db = m.getDB( "test" );
t = db[ baseName ];
t.drop();
@@ -61,9 +61,9 @@ assert.eq( 1000, db.eval( function() { return db[ "jstests_auth_auth1" ].count()
assert.eq( 1000, t.group( p ).length );
-//var p = { key : { i : true } ,
-// reduce : function(obj,prev) { db.jstests_auth_auth1.save( {i:10000} ); prev.count++; },
-//initial: { count: 0 }
-//};
-//
-//assert.throws( t.group( p ) );
+var p = { key : { i : true } ,
+ reduce : function(obj,prev) { db.jstests_auth_auth1.save( {i:10000} ); prev.count++; },
+initial: { count: 0 }
+};
+
+assert.throws( function() { t.group( p ) } );