Permalink
Browse files

SERVER-2111 fix test

  • Loading branch information...
1 parent 4c66fe2 commit e1f8ea459eaeb70622679d35736a035f81b8edb2 @astaple astaple committed Apr 13, 2011
Showing with 5 additions and 3 deletions.
  1. +5 −3 jstests/dbcase.js
View
@@ -21,7 +21,9 @@ printjson( db.getMongo().getDBs().databases );
a.dropDatabase();
b.dropDatabase();
-// 'a' wil be present as a read only db because we issued a command with it in the ns.
-assert.neq( -1, db.getMongo().getDBNames().indexOf( a.getName() ) );
-assert.eq( -1, db.getMongo().getDBNames().indexOf( b.getName() ) );
+ai = db.getMongo().getDBNames().indexOf( a.getName() );
+bi = db.getMongo().getDBNames().indexOf( b.getName() );
+// One of these dbs may exist if there is a slave active, but they must
+// not both exist.
+assert( ai == -1 || bi == -1 );
printjson( db.getMongo().getDBs().databases );

0 comments on commit e1f8ea4

Please sign in to comment.