1
0
Fork 0

Fix maintenance test. (#6326)

This commit is contained in:
Max Neunhöffer 2018-08-31 21:54:55 +02:00 committed by GitHub
parent 3c638849bd
commit 071966ce94
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 7 additions and 3 deletions

View File

@ -781,13 +781,17 @@ TEST_CASE("ActionPhaseOne", "[cluster][maintenance]") {
plan.toBuilder().slice(), node.second.toBuilder().slice(), node.first,
errors, actions);
if (actions.size() != 1) {
if (actions.size() != 2) {
std::cout << actions << std::endl;
}
REQUIRE(actions.size() == 1);
REQUIRE(actions.front().name() == "ResignShardLeadership");
REQUIRE(actions.size() == 2);
REQUIRE(actions.front().name() == "UpdateCollection");
REQUIRE(actions.front().get(DATABASE) == dbname);
REQUIRE(actions.front().get(SHARD) == shname);
REQUIRE(actions.front().get("localLeader") == std::string(""));
REQUIRE(actions[1].name() == "ResignShardLeadership");
REQUIRE(actions[1].get(DATABASE) == dbname);
REQUIRE(actions[1].get(SHARD) == shname);
}
}