Skip to content

Commit 0527b05

Browse files
authored
RUST-893 Add connectivity tests for Atlas serverless load-balanced instances (#505)
1 parent f555079 commit 0527b05

File tree

2 files changed

+18
-0
lines changed

2 files changed

+18
-0
lines changed

.evergreen/config.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -389,6 +389,8 @@ functions:
389389
export MONGO_ATLAS_TESTS=1
390390
export MONGO_ATLAS_FREE_TIER_REPL_URI='${MONGO_ATLAS_FREE_TIER_REPL_URI}'
391391
export MONGO_ATLAS_FREE_TIER_REPL_URI_SRV='${MONGO_ATLAS_FREE_TIER_REPL_URI_SRV}'
392+
export MONGO_ATLAS_SERVERLESS_URI='${MONGO_ATLAS_SERVERLESS_URI}'
393+
export MONGO_ATLAS_SERVERLESS_URI_SRV='${MONGO_ATLAS_SERVERLESS_URI_SRV}'
392394
ASYNC_RUNTIME=${ASYNC_RUNTIME} .evergreen/run-atlas-tests.sh
393395
394396
"run ocsp test":

src/test/atlas_connectivity.rs

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,3 +49,19 @@ async fn atlas_repl_set_srv() {
4949
)
5050
.await;
5151
}
52+
53+
#[cfg_attr(feature = "tokio-runtime", tokio::test)]
54+
#[cfg_attr(feature = "async-std-runtime", async_std::test)]
55+
async fn atlas_serverless() {
56+
run_test("MONGO_ATLAS_SERVERLESS_URI", None).await;
57+
}
58+
59+
#[cfg_attr(feature = "tokio-runtime", tokio::test)]
60+
#[cfg_attr(feature = "async-std-runtime", async_std::test)]
61+
async fn atlas_serverless_srv() {
62+
run_test(
63+
"MONGO_ATLAS_SERVERLESS_URI_SRV",
64+
Some(ResolverConfig::cloudflare()),
65+
)
66+
.await;
67+
}

0 commit comments

Comments
 (0)