diff options
Diffstat (limited to 'src/mongo/db/repl/replication_coordinator_impl_test.cpp')
-rw-r--r-- | src/mongo/db/repl/replication_coordinator_impl_test.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/mongo/db/repl/replication_coordinator_impl_test.cpp b/src/mongo/db/repl/replication_coordinator_impl_test.cpp index ff034802740..f19ee0d2bd0 100644 --- a/src/mongo/db/repl/replication_coordinator_impl_test.cpp +++ b/src/mongo/db/repl/replication_coordinator_impl_test.cpp @@ -1212,8 +1212,8 @@ TEST_F(ReplCoordTest, } TEST_F(ReplCoordTest, NodeReturnsNotMasterWhenSteppingDownBeforeSatisfyingAWriteConcern) { - // Test that a thread blocked in awaitReplication will be woken up and return NotMaster - // if the node steps down while it is waiting. + // Test that a thread blocked in awaitReplication will be woken up and return PrimarySteppedDown + // (a NotMasterError) if the node steps down while it is waiting. assertStartSuccess(BSON("_id" << "mySet" << "version" << 2 << "members" @@ -1917,7 +1917,7 @@ TEST_F(StepDownTestWithUnelectableNode, ASSERT_TRUE(repl->getMemberState().secondary()); } -TEST_F(StepDownTest, NodeReturnsNotMasterWhenAskedToStepDownAsANonPrimaryNode) { +TEST_F(StepDownTest, NodeReturnsNotWritablePrimaryWhenAskedToStepDownAsANonPrimaryNode) { const auto opCtx = makeOperationContext(); OpTimeWithTermOne optime1(100, 1); @@ -1930,7 +1930,7 @@ TEST_F(StepDownTest, NodeReturnsNotMasterWhenAskedToStepDownAsANonPrimaryNode) { ASSERT_THROWS_CODE( getReplCoord()->stepDown(opCtx.get(), false, Milliseconds(0), Milliseconds(0)), AssertionException, - ErrorCodes::NotMaster); + ErrorCodes::NotWritablePrimary); ASSERT_TRUE(getReplCoord()->getMemberState().secondary()); } |