*
*/
-#include <config.h>
+#include <mem_config.h>
#include <libtest/test.hpp>
using namespace libtest;
Test cases
*/
-#include <libmemcached/memcached.h>
+#include <libmemcached-1.0/memcached.h>
static test_return_t pre_sasl(memcached_st *)
{
- if (LIBMEMCACHED_WITH_SASL_SUPPORT == 0)
- {
- return TEST_SKIPPED;
- }
+ SKIP_IF(true);
+#if 0
+ SKIP_IF_(true, "currently we are not testing sasl support");
+#endif
+ SKIP_IF(LIBMEMCACHED_WITH_SASL_SUPPORT == 0);
return TEST_SUCCESS;
}
*/
static test_return_t sasl_auth_test(memcached_st *memc)
{
+#ifdef LIBMEMCACHED_WITH_SASL_SUPPORT
if (LIBMEMCACHED_WITH_SASL_SUPPORT)
{
test_compare(MEMCACHED_SUCCESS, memcached_set(memc, "foo", 3, "bar", 3, (time_t)0, (uint32_t)0));
memcached_quit(memc);
return TEST_SUCCESS;
}
+#else
+ (void)memc;
+#endif
return TEST_SKIPPED;
}
#include "tests/libmemcached_world.h"
-void get_world(Framework *world)
+void get_world(libtest::Framework* world)
{
- world->collections= collection;
-
- world->_create= (test_callback_create_fn*)world_create;
- world->_destroy= (test_callback_destroy_fn*)world_destroy;
-
- world->item._startup= (test_callback_fn*)world_test_startup;
- world->_on_error= (test_callback_error_fn*)world_on_error;
+ world->collections(collection);
- world->collection_startup= (test_callback_fn*)world_container_startup;
- world->collection_shutdown= (test_callback_fn*)world_container_shutdown;
+ world->create((test_callback_create_fn*)world_create);
+ world->destroy((test_callback_destroy_fn*)world_destroy);
world->set_runner(new LibmemcachedRunner);