diff options
author | Mathias Stearn <mathias@10gen.com> | 2017-06-20 10:55:43 -0400 |
---|---|---|
committer | Mathias Stearn <mathias@10gen.com> | 2017-06-28 11:57:04 -0400 |
commit | e3fe73454a6e558fc61c19456510d5f93152721d (patch) | |
tree | 811f7d2d61f8512fe1bd653e278a06767aa677e8 /src/mongo/client/dbclient_rs_test.cpp | |
parent | e777062a8a4a6084472039e8d1d4008f42f777fb (diff) | |
download | mongo-e3fe73454a6e558fc61c19456510d5f93152721d.tar.gz |
SERVER-29319 Delete DBClient::runCommandWithMetadata{,AndTarget}
Diffstat (limited to 'src/mongo/client/dbclient_rs_test.cpp')
-rw-r--r-- | src/mongo/client/dbclient_rs_test.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/mongo/client/dbclient_rs_test.cpp b/src/mongo/client/dbclient_rs_test.cpp index b90b4fe75ee..1a97f870bcf 100644 --- a/src/mongo/client/dbclient_rs_test.cpp +++ b/src/mongo/client/dbclient_rs_test.cpp @@ -102,8 +102,8 @@ void assertOneOfNodesSelected(MockReplicaSet* replSet, bool secondaryOk = (rp != ReadPreference::PrimaryOnly); auto tagSet = secondaryOk ? TagSet() : TagSet::primaryOnly(); // We need the command to be a "SecOk command" - auto res = replConn.runCommandWithMetadata( - "foo", "dbStats", makeMetadata(rp, tagSet), BSON("dbStats" << 1)); + auto res = replConn.runCommand( + OpMsgRequest::fromDBAndBody("foo", BSON("dbStats" << 1), makeMetadata(rp, tagSet))); stdx::unordered_set<HostAndPort> hostSet; for (const auto& hostName : hostNames) { hostSet.emplace(hostName); @@ -229,8 +229,8 @@ void assertRunCommandWithReadPrefThrows(MockReplicaSet* replSet, ReadPreference TagSet ts = isPrimaryOnly ? TagSet::primaryOnly() : TagSet(); DBClientReplicaSet replConn(replSet->getSetName(), replSet->getHosts(), StringData()); - ASSERT_THROWS(replConn.runCommandWithMetadata( - "foo", "whoami", makeMetadata(rp, ts), BSON("dbStats" << 1)), + ASSERT_THROWS(replConn.runCommand(OpMsgRequest::fromDBAndBody( + "foo", BSON("dbStats" << 1), makeMetadata(rp, ts))), AssertionException); } |