X-Git-Url: https://git.m6w6.name/?a=blobdiff_plain;ds=sidebyside;f=tests%2Ferror_conditions.cc;h=66e7c44e02534b085c368791647c2cca6b005aa1;hb=d3e39fdf907d5f82e3f378d52f27bdc13e3eb891;hp=b46b3ca28bab3dff9df2f605daad5aac36df7c06;hpb=1f5cf20c75c7187df1d648a5a200b52db3f17db1;p=awesomized%2Flibmemcached diff --git a/tests/error_conditions.cc b/tests/error_conditions.cc index b46b3ca2..66e7c44e 100644 --- a/tests/error_conditions.cc +++ b/tests/error_conditions.cc @@ -36,35 +36,29 @@ */ #include +#include + +#define BUILDING_LIBMEMCACHED #include #include -#include -#include -#ifdef __cplusplus -extern "C" { -#endif +#include -test_return_t memcached_increment_MEMCACHED_NO_SERVERS(memcached_st *junk) +test_return_t memcached_increment_MEMCACHED_NO_SERVERS(memcached_st *) { - (void)junk; memcached_st *memc_ptr; memc_ptr= memcached_create(NULL); test_true(memc_ptr); - memcached_increment(memc_ptr, memcached_string_with_size("dead key"), 1, NULL); + memcached_increment(memc_ptr, test_literal_param("dead key"), 1, NULL); test_true(memcached_last_error(memc_ptr) == MEMCACHED_NO_SERVERS); - memcached_increment(memc_ptr, memcached_string_with_size("dead key"), 1, NULL); + memcached_increment(memc_ptr, test_literal_param("dead key"), 1, NULL); test_true(memcached_last_error(memc_ptr) == MEMCACHED_NO_SERVERS); memcached_free(memc_ptr); return TEST_SUCCESS; } - -#ifdef __cplusplus -} -#endif