Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change timeout in ping/diagnostics timeout tests from 1 to 0 milliseconds #503

Merged
merged 2 commits into from Jan 18, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 2 additions & 2 deletions test/test_integration_diagnostics.cxx
Expand Up @@ -254,7 +254,7 @@ TEST_CASE("integration: ping allows setting timeout", "[integration]")
{
auto barrier = std::make_shared<std::promise<couchbase::core::diag::ping_result>>();
auto f = barrier->get_future();
integration.cluster.ping({}, {}, {}, std::chrono::milliseconds(1), [barrier](couchbase::core::diag::ping_result&& resp) mutable {
integration.cluster.ping({}, {}, {}, std::chrono::milliseconds(0), [barrier](couchbase::core::diag::ping_result&& resp) mutable {
barrier->set_value(std::move(resp));
});
auto res = f.get();
Expand Down Expand Up @@ -306,7 +306,7 @@ TEST_CASE("integration: ping allows setting timeout", "[integration]")
{
auto cluster = couchbase::cluster(integration.cluster);

auto res = cluster.ping(couchbase::ping_options().timeout(std::chrono::milliseconds{ 1 })).get();
auto res = cluster.ping(couchbase::ping_options().timeout(std::chrono::milliseconds(0))).get();

REQUIRE(res.endpoints().size() > 0);

Expand Down