summaryrefslogtreecommitdiff
path: root/src/mongo/db/repl/replication_coordinator_impl_test.cpp
diff options
context:
space:
mode:
authorMatthew Russotto <matthew.russotto@10gen.com>2017-11-28 10:44:24 -0500
committerMatthew Russotto <matthew.russotto@10gen.com>2017-11-28 15:59:13 -0500
commita25df7d03ac286f28eadebdd361802ad522e74e9 (patch)
tree567f75f4898eaf9e6fcbcd5f10c1ccdcf00754f9 /src/mongo/db/repl/replication_coordinator_impl_test.cpp
parent26b42901e302db19cfbdbf3726b7be6fb624f4f5 (diff)
downloadmongo-a25df7d03ac286f28eadebdd361802ad522e74e9.tar.gz
SERVER-30626 Replace class TopologyCoordinator::Role with enum class for simplicity.
Diffstat (limited to 'src/mongo/db/repl/replication_coordinator_impl_test.cpp')
-rw-r--r--src/mongo/db/repl/replication_coordinator_impl_test.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/mongo/db/repl/replication_coordinator_impl_test.cpp b/src/mongo/db/repl/replication_coordinator_impl_test.cpp
index a7201c03d32..c8058823ab8 100644
--- a/src/mongo/db/repl/replication_coordinator_impl_test.cpp
+++ b/src/mongo/db/repl/replication_coordinator_impl_test.cpp
@@ -2583,7 +2583,7 @@ TEST_F(ReplCoordTest, DoNotAllowSettingMaintenanceModeWhileConductingAnElection)
.transitional_ignore();
// Can't modify maintenance mode when running for election (before and after dry run).
- ASSERT_EQUALS(TopologyCoordinator::Role::follower, getTopoCoord().getRole());
+ ASSERT_EQUALS(TopologyCoordinator::Role::kFollower, getTopoCoord().getRole());
auto net = this->getNet();
net->enterNetwork();
auto when = getReplCoord()->getElectionTimeout_forTest();
@@ -2596,14 +2596,14 @@ TEST_F(ReplCoordTest, DoNotAllowSettingMaintenanceModeWhileConductingAnElection)
}
ASSERT_EQUALS(when, net->now());
net->exitNetwork();
- ASSERT_EQUALS(TopologyCoordinator::Role::candidate, getTopoCoord().getRole());
+ ASSERT_EQUALS(TopologyCoordinator::Role::kCandidate, getTopoCoord().getRole());
Status status = getReplCoord()->setMaintenanceMode(false);
ASSERT_EQUALS(ErrorCodes::NotSecondary, status);
status = getReplCoord()->setMaintenanceMode(true);
ASSERT_EQUALS(ErrorCodes::NotSecondary, status);
simulateSuccessfulDryRun();
- ASSERT_EQUALS(TopologyCoordinator::Role::candidate, getTopoCoord().getRole());
+ ASSERT_EQUALS(TopologyCoordinator::Role::kCandidate, getTopoCoord().getRole());
status = getReplCoord()->setMaintenanceMode(false);
ASSERT_EQUALS(ErrorCodes::NotSecondary, status);
status = getReplCoord()->setMaintenanceMode(true);