diff options
Diffstat (limited to 'jstests/auth/indexSystemUsers.js')
-rw-r--r-- | jstests/auth/indexSystemUsers.js | 20 |
1 files changed, 9 insertions, 11 deletions
diff --git a/jstests/auth/indexSystemUsers.js b/jstests/auth/indexSystemUsers.js index ef7187dfe46..fd33e906974 100644 --- a/jstests/auth/indexSystemUsers.js +++ b/jstests/auth/indexSystemUsers.js @@ -18,17 +18,15 @@ assert.eq(13, res.code); // unauthorized assert.writeError(adminDB.exploit.system.indexes.insert( {ns: "admin.system.users", key: {haxx: 1.0}, name: "haxx_1", unique: true, dropDups: true})); // Make sure that no indexes were built. -var collectionInfosCursor = - adminDB.runCommand("listCollections", - { - filter: { - $and: [ - {name: /^admin\.system\.users\.\$/}, - {name: {$ne: "admin.system.users.$_id_"}}, - {name: {$ne: "admin.system.users.$user_1_db_1"}} - ] - } - }); +var collectionInfosCursor = adminDB.runCommand("listCollections", { + filter: { + $and: [ + {name: /^admin\.system\.users\.\$/}, + {name: {$ne: "admin.system.users.$_id_"}}, + {name: {$ne: "admin.system.users.$user_1_db_1"}} + ] + } +}); assert.eq([], new DBCommandCursor(adminDB.getMongo(), collectionInfosCursor).toArray()); adminDB.logout(); |