diff options
author | Louis Williams <louis.williams@mongodb.com> | 2022-01-24 11:35:31 +0000 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2022-02-01 16:20:27 +0000 |
commit | 537b62b26124d966cfe6ebba34e06b23e0ebac2b (patch) | |
tree | fd9a9642e7264cd990ae101ff664402b48290a47 | |
parent | e26f743583dc6f5f487a2c0bef9c4e86ed76fbd0 (diff) | |
download | mongo-537b62b26124d966cfe6ebba34e06b23e0ebac2b.tar.gz |
SERVER-62511 Fix race in dbcheck_no_history_on_secondary.js
(cherry picked from commit 2f9bf168ae85dfd3a5bb9c15c5e534660562470c)
-rw-r--r-- | jstests/noPassthrough/dbcheck_no_history_on_secondary.js | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/jstests/noPassthrough/dbcheck_no_history_on_secondary.js b/jstests/noPassthrough/dbcheck_no_history_on_secondary.js index a79adf04dfd..376e361aa7d 100644 --- a/jstests/noPassthrough/dbcheck_no_history_on_secondary.js +++ b/jstests/noPassthrough/dbcheck_no_history_on_secondary.js @@ -69,7 +69,8 @@ replTest.awaitReplication(); { // Expect an error on the secondary. const healthlog = secondary.getDB('local').system.healthlog; - assert.soon(() => healthlog.find().hasNext(), 'expected health log to not be empty'); + assert.soon(() => healthlog.find({severity: 'error'}).hasNext(), + 'expected health log to have an error, but found none'); const errors = healthlog.find({severity: 'error'}); assert(errors.hasNext(), 'expected error, found none'); |