diff options
Diffstat (limited to 'jstests/replsets/initial_sync_fails_when_source_removed.js')
-rw-r--r-- | jstests/replsets/initial_sync_fails_when_source_removed.js | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/jstests/replsets/initial_sync_fails_when_source_removed.js b/jstests/replsets/initial_sync_fails_when_source_removed.js index a171f92723b..8eb2221c771 100644 --- a/jstests/replsets/initial_sync_fails_when_source_removed.js +++ b/jstests/replsets/initial_sync_fails_when_source_removed.js @@ -17,6 +17,10 @@ const primary = rst.getPrimary(); const primaryDb = primary.getDB("test"); const initialSyncSource = rst.getSecondary(); +// The default WC is majority and this test can't satisfy majority writes. +assert.commandWorked(primary.adminCommand( + {setDefaultRWConcern: 1, defaultWriteConcern: {w: 1}, writeConcern: {w: "majority"}})); + // Add some data to be cloned. assert.commandWorked(primaryDb.test.insert([{a: 1}, {b: 2}, {c: 3}])); rst.awaitReplication(); |