Update updates to a current version of bootstrap.
[awesomized/libmemcached] / tests / cycle.cc
index ac087f4f2e6f47c28e24c426b4231ff02a63cf24..cfaccb7ed8188899af6207477218d2c93d2f7ec5 100644 (file)
@@ -43,7 +43,7 @@
 #include <libtest/test.hpp>
 
 using namespace libtest;
-#include <libmemcached/memcached.h>
+#include <libmemcached-1.0/memcached.h>
 
 static test_return_t server_startup_single_TEST(void *obj)
 {
@@ -57,6 +57,8 @@ static test_return_t server_startup_single_TEST(void *obj)
 
 static test_return_t server_startup_multiple_TEST(void *obj)
 {
+  test_skip(true, jenkins_is_caller());
+
   server_startup_st *servers= (server_startup_st*)obj;
   for (size_t x= 0; x < 10; x++)
   {
@@ -70,7 +72,7 @@ static test_return_t server_startup_multiple_TEST(void *obj)
 static test_return_t shutdown_and_remove_TEST(void *obj)
 {
   server_startup_st *servers= (server_startup_st*)obj;
-  servers->shutdown_and_remove();
+  servers->clear();
 
   return TEST_SUCCESS;
 }
@@ -106,7 +108,7 @@ static test_return_t validate_sanity_INIT(void *object)
 static test_return_t collection_FINAL(void *object)
 {
   server_startup_st *servers= (server_startup_st*)object;
-  servers->shutdown_and_remove();
+  servers->clear();
 
   return TEST_SUCCESS;
 }
@@ -116,14 +118,20 @@ collection_st collection[] ={
   {0, 0, 0, 0}
 };
 
-static void *world_create(server_startup_st& servers, test_return_t& )
+static void *world_create(server_startup_st& servers, test_return_t& error)
 {
+  if (libtest::has_memcached() == false)
+  {
+    error= TEST_SKIPPED;
+    return NULL;
+  }
+
   return &servers;
 }
 
-void get_world(Framework *world)
+void get_world(libtest::Framework* world)
 {
-  world->collections= collection;
-  world->_create= world_create;
+  world->collections(collection);
+  world->create(world_create);
 }