summaryrefslogtreecommitdiff
path: root/src/mongo/client/remote_command_retry_scheduler_test.cpp
diff options
context:
space:
mode:
authorMathias Stearn <mathias@10gen.com>2018-07-25 17:33:21 -0400
committerMathias Stearn <mathias@10gen.com>2018-07-30 14:13:08 -0400
commita5f3bf878d5059215fbc5a5a371aaf2d8a85e8b9 (patch)
tree86baac1bd319bbe02ca31c2404d0b631ff5a25ad /src/mongo/client/remote_command_retry_scheduler_test.cpp
parentcca8ad6cf6f47e86158a8636b6a07743bd115fcc (diff)
downloadmongo-a5f3bf878d5059215fbc5a5a371aaf2d8a85e8b9.tar.gz
SERVER-33135 Remove metadata accessors from command reply APIs
Now that OP_COMMAND is dead, all remaining implementations return the same BSONObj for data and metadata.
Diffstat (limited to 'src/mongo/client/remote_command_retry_scheduler_test.cpp')
-rw-r--r--src/mongo/client/remote_command_retry_scheduler_test.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/mongo/client/remote_command_retry_scheduler_test.cpp b/src/mongo/client/remote_command_retry_scheduler_test.cpp
index a3c23c6b05d..783ab23d4c0 100644
--- a/src/mongo/client/remote_command_retry_scheduler_test.cpp
+++ b/src/mongo/client/remote_command_retry_scheduler_test.cpp
@@ -378,7 +378,7 @@ TEST_F(RemoteCommandRetrySchedulerTest, SchedulerInvokesCallbackOnFirstSuccessfu
start(&scheduler);
// Elapsed time in response is ignored on successful responses.
- ResponseStatus response(BSON("ok" << 1 << "x" << 123), BSON("z" << 456), Milliseconds(100));
+ ResponseStatus response(BSON("ok" << 1 << "x" << 123 << "z" << 456), Milliseconds(100));
processNetworkResponse(response);
checkCompletionStatus(&scheduler, callback, response);
@@ -400,8 +400,9 @@ TEST_F(RemoteCommandRetrySchedulerTest, SchedulerIgnoresEmbeddedErrorInSuccessfu
// This is the case with some commands (e.g. find) which do not always return errors using the
// wire protocol.
ResponseStatus response(BSON("ok" << 0 << "code" << int(ErrorCodes::FailedToParse) << "errmsg"
- << "injected error"),
- BSON("z" << 456),
+ << "injected error"
+ << "z"
+ << 456),
Milliseconds(100));
processNetworkResponse(response);
@@ -458,7 +459,7 @@ TEST_F(RemoteCommandRetrySchedulerTest, SchedulerShouldRetryUntilSuccessfulRespo
processNetworkResponse({ErrorCodes::HostNotFound, "first", Milliseconds(0)});
- ResponseStatus response(BSON("ok" << 1 << "x" << 123), BSON("z" << 456), Milliseconds(100));
+ ResponseStatus response(BSON("ok" << 1 << "x" << 123 << "z" << 456), Milliseconds(100));
processNetworkResponse(response);
checkCompletionStatus(&scheduler, callback, response);
}