diff options
author | Kaitlin Mahar <kaitlin.mahar@mongodb.com> | 2023-04-18 14:18:32 +0000 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2023-04-18 15:56:42 +0000 |
commit | 983d4ca5e0c50d644c64be42bd59df481dee0a57 (patch) | |
tree | a358e1b82a15099efa3a7f1de78da103ebcd6c3e /jstests/replsets | |
parent | f2ac336d5d4458cd66b6cb0908a932e567beec89 (diff) | |
download | mongo-983d4ca5e0c50d644c64be42bd59df481dee0a57.tar.gz |
SERVER-76139 sync_source_changes.js should wait for node to no longer be newly added before asserting on sync source
Diffstat (limited to 'jstests/replsets')
-rw-r--r-- | jstests/replsets/sync_source_changes.js | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/jstests/replsets/sync_source_changes.js b/jstests/replsets/sync_source_changes.js index 38e55dac5e7..02bce0ba3b9 100644 --- a/jstests/replsets/sync_source_changes.js +++ b/jstests/replsets/sync_source_changes.js @@ -56,6 +56,9 @@ rst.waitForState(newNode, ReplSetTest.State.SECONDARY); rst.awaitReplication(); rst.awaitSecondaryNodes(); +// Wait for the new node to no longer be newlyAdded, so that it becomes a voting node. +rst.waitForAllNewlyAddedRemovals(); + // Assure that node 2 will set node 0 as its sync source, since it is the best option. assertSyncSourceChangesTo(rst, newNode, rst.nodes[0]); |