testing: fix test case names for CTest
[m6w6/libmemcached] / testing / tests / memcached / util.cpp
index 11f2a460278ad030a96cc3d9fd850467e68da077..1ea6118603b98d64839d18070b32694a18804d2d 100644 (file)
@@ -12,7 +12,7 @@ static memcached_return_t ping_callback(const memcached_st *, const memcached_in
   return MEMCACHED_SUCCESS;
 }
 
-TEST_CASE("memcached util") {
+TEST_CASE("memcached_util") {
   SECTION("version_check") {
     auto test = MemcachedCluster::mixed();
     auto memc = &test.memc;
@@ -63,4 +63,14 @@ TEST_CASE("memcached util") {
 
     REQUIRE_SUCCESS(memcached_server_cursor(memc, fptr, nullptr, 1));
   }
+
+  SECTION("flush") {
+    auto test = MemcachedCluster::network();
+
+    for (auto &server : test.cluster.getServers()) {
+      memcached_return_t rc;
+      REQUIRE(libmemcached_util_flush("localhost", get<int>(server.getSocketOrPort()), &rc));
+      REQUIRE_SUCCESS(rc);
+    }
+  }
 }