Skip to content

Commit c2439a4

Browse files
authored
Improve stability of update collection max expiry tests (#838)
1 parent f489098 commit c2439a4

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

test/test_integration_management.cxx

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1633,9 +1633,8 @@ TEST_CASE("integration: collection management update collection with max expiry"
16331633
REQUIRE(test::utils::wait_until([&]() {
16341634
collection =
16351635
get_collection(integration.cluster, integration.ctx.bucket, scope_name, collection_name);
1636-
return collection.has_value();
1636+
return collection.has_value() && collection->max_expiry == 0;
16371637
}));
1638-
REQUIRE(collection->max_expiry == 0);
16391638
}
16401639

16411640
SECTION("positive max expiry")
@@ -1663,9 +1662,8 @@ TEST_CASE("integration: collection management update collection with max expiry"
16631662
REQUIRE(test::utils::wait_until([&]() {
16641663
collection =
16651664
get_collection(integration.cluster, integration.ctx.bucket, scope_name, collection_name);
1666-
return collection.has_value();
1665+
return collection.has_value() && collection->max_expiry == 3600;
16671666
}));
1668-
REQUIRE(collection->max_expiry == 3600);
16691667
}
16701668

16711669
SECTION("setting max expiry to no-expiry")
@@ -1694,9 +1692,8 @@ TEST_CASE("integration: collection management update collection with max expiry"
16941692
REQUIRE(test::utils::wait_until([&]() {
16951693
collection =
16961694
get_collection(integration.cluster, integration.ctx.bucket, scope_name, collection_name);
1697-
return collection.has_value();
1695+
return collection.has_value() && collection->max_expiry == -1;
16981696
}));
1699-
REQUIRE(collection->max_expiry == -1);
17001697
} else {
17011698
SECTION("core API")
17021699
{

0 commit comments

Comments
 (0)