summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorADAM David Alan Martin <adam.martin@10gen.com>2017-11-22 17:37:12 -0500
committerADAM David Alan Martin <adam.martin@10gen.com>2017-11-22 17:41:31 -0500
commit51eef7921817b9438e845106d8a438249c3a72a4 (patch)
treeba509a4c33530d71d7afde38c1796a7ad10d6971
parent4b3e99874aaa66ee0b88390663536337f3f54e60 (diff)
downloadmongo-51eef7921817b9438e845106d8a438249c3a72a4.tar.gz
SERVER-32077 Fix connection string test.
(cherry picked from commit 4c00395b84400df45bcce4413b6ea895ead7eff4)
-rw-r--r--src/mongo/client/mongo_uri_test.cpp29
1 files changed, 15 insertions, 14 deletions
diff --git a/src/mongo/client/mongo_uri_test.cpp b/src/mongo/client/mongo_uri_test.cpp
index c49df4d7cdc..c361346eef7 100644
--- a/src/mongo/client/mongo_uri_test.cpp
+++ b/src/mongo/client/mongo_uri_test.cpp
@@ -657,59 +657,60 @@ TEST(MongoURI, srvRecordTest) {
{{"localhost.test.build.10gen.cc.", 27017}},
{{"someOption", "someValue"},
{"someOtherOption", "someOtherValue"},
- {"connectTimeoutMS", "300000"},
- {"socketTimeoutMS", "300000"}}},
+ {"replicaSet", "repl0"},
+ {"authSource", "thisDB"}}},
{"mongodb+srv://user:password@test5.test.build.10gen.cc/"
- "database?someOption=someValue&socketTimeoutMS=100&someOtherOption=someOtherValue",
+ "database?someOption=someValue&authSource=anotherDB&someOtherOption=someOtherValue",
"user",
"password",
"database",
{{"localhost.test.build.10gen.cc.", 27017}},
{{"someOption", "someValue"},
{"someOtherOption", "someOtherValue"},
- {"connectTimeoutMS", "300000"},
- {"socketTimeoutMS", "100"}}},
+ {"replicaSet", "repl0"},
+ {"replicaSet", "repl0"},
+ {"authSource", "anotherDB"}}},
{"mongodb+srv://test6.test.build.10gen.cc/",
"",
"",
"",
{{"localhost.test.build.10gen.cc.", 27017}},
- {{"connectTimeoutMS", "200000"}, {"socketTimeoutMS", "200000"}}},
+ {{"replicaSet", "repl0"}, {"authSource", "otherDB"}}},
{"mongodb+srv://test6.test.build.10gen.cc/database",
"",
"",
"database",
{{"localhost.test.build.10gen.cc.", 27017}},
- {{"connectTimeoutMS", "200000"}, {"socketTimeoutMS", "200000"}}},
+ {{"replicaSet", "repl0"}, {"authSource", "otherDB"}}},
- {"mongodb+srv://test6.test.build.10gen.cc/?connectTimeoutMS=300000",
+ {"mongodb+srv://test6.test.build.10gen.cc/?authSource=anotherDB",
"",
"",
"",
{{"localhost.test.build.10gen.cc.", 27017}},
- {{"connectTimeoutMS", "300000"}, {"socketTimeoutMS", "200000"}}},
+ {{"replicaSet", "repl0"}, {"authSource", "anotherDB"}}},
{"mongodb+srv://test6.test.build.10gen.cc/?irrelevantOption=irrelevantValue",
"",
"",
"",
{{"localhost.test.build.10gen.cc.", 27017}},
- {{"connectTimeoutMS", "200000"},
- {"socketTimeoutMS", "200000"},
+ {{"replicaSet", "repl0"},
+ {"authSource", "otherDB"},
{"irrelevantOption", "irrelevantValue"}}},
{"mongodb+srv://test6.test.build.10gen.cc/"
- "?irrelevantOption=irrelevantValue&connectTimeoutMS=300000",
+ "?irrelevantOption=irrelevantValue&authSource=anotherDB",
"",
"",
"",
{{"localhost.test.build.10gen.cc.", 27017}},
- {{"connectTimeoutMS", "300000"},
- {"socketTimeoutMS", "200000"},
+ {{"replicaSet", "repl0"},
+ {"authSource", "anotherDB"},
{"irrelevantOption", "irrelevantValue"}}},
};