- Clients (src/bin):
- consolidate CLI
- convert to proper C++ where applicable
+- Stats:
+ - redo
## Legacy:
#pragma once
+#define YYDEBUG 1
#ifndef YY_EXTRA_TYPE
# define YY_EXTRA_TYPE Context*
// return a generic message
if (strcmp(error_arg, "syntax error") != 0)
{
- memcached_set_parser_error(*memc, MEMCACHED_AT, "Error occured during parsing (%s)", error_arg);
+ memcached_set_parser_error(*memc, MEMCACHED_AT, "Error occured during parsing (%s): last_token=%s(%d)", error_arg, last_token_str, last_token);
return;
}
}
#define YY_FATAL_ERROR(msg) \
-{ \
+{\
+ fprintf(stderr, "%s\n", msg); \
}
#define YYSTYPE CONFIG_STYPE
${CMAKE_BINARY_DIR}
${CMAKE_SOURCE_DIR}/src
${CMAKE_BINARY_DIR}/src)
-target_link_libraries(runtests PRIVATE libhashkit libmemcached libmemcachedutil)
+target_link_libraries(runtests PRIVATE libhashkit libmemcachedinternal libmemcachedutil)
add_dependencies(runtests ${CLIENTS})
catch_discover_tests(runtests
--- /dev/null
+--SOCKET="/var/run/memcached/memcached.sock"
, proto{move(serv)}
{
if (!cnt) {
- count = thread::hardware_concurrency()/2 ?: 4;
+ count = thread::hardware_concurrency()/2;
+ if (count < 4) {
+ count = 4;
+ }
}
reset();
}
memcached_st *operator * () {
return memc;
}
+ auto operator ->() {
+ return memc;
+ }
};
template<class T>
--- /dev/null
+#warning TODO
#include "test/lib/MemcachedCluster.hpp"
TEST_CASE("memcached_exist") {
- pair<string, MemcachedCluster> tests[]{
- {"bin_mixed", MemcachedCluster::mixed()},
- {"network", MemcachedCluster::network()},
- {"socket", MemcachedCluster::socket()}
- };
+ MemcachedCluster test;
+ auto memc = &test.memc;
+ auto binary = GENERATE(0, 1);
- tests[0].second.enableBinaryProto();
+ test.enableBinaryProto(binary);
+ INFO("binary: " << binary);
- LOOPED_SECTION(tests) {
- auto memc = &test.memc;
+ SECTION("initial not found") {
+ REQUIRE_RC(MEMCACHED_NOTFOUND,memcached_exist(memc, S("frog")));
+ }
+
+ SECTION("set found") {
+ REQUIRE_SUCCESS(memcached_set(memc, S("frog"), S("frog"), 0, 0));
+ REQUIRE_SUCCESS(memcached_exist(memc, S("frog")));
+
+ SECTION("deleted not found") {
+ REQUIRE_SUCCESS(memcached_delete(memc, S("frog"), 0));
+ REQUIRE_RC(MEMCACHED_NOTFOUND, memcached_exist(memc, S("frog")));
+ }
+ }
+ SECTION("by key") {
SECTION("initial not found") {
- REQUIRE_RC(MEMCACHED_NOTFOUND,memcached_exist(memc, S("frog")));
+ REQUIRE_RC(MEMCACHED_NOTFOUND, memcached_exist_by_key(memc, S("master"), S("frog")));
}
SECTION("set found") {
- REQUIRE_SUCCESS(memcached_set(memc, S("frog"), S("frog"), 0, 0));
- REQUIRE_SUCCESS(memcached_exist(memc, S("frog")));
+ REQUIRE_SUCCESS(memcached_set_by_key(memc, S("master"), S("frog"), S("frog"), 0, 0));
+ REQUIRE_SUCCESS(memcached_exist_by_key(memc, S("master"), S("frog")));
- SECTION("deleted not found") {
- REQUIRE_SUCCESS(memcached_delete(memc, S("frog"), 0));
- REQUIRE_RC(MEMCACHED_NOTFOUND, memcached_exist(memc, S("frog")));
- }
- }
-
- SECTION("by key") {
- SECTION("initial not found") {
+ SECTION("deleted not found") {
+ REQUIRE_SUCCESS(memcached_delete_by_key(memc, S("master"), S("frog"), 0));
REQUIRE_RC(MEMCACHED_NOTFOUND, memcached_exist_by_key(memc, S("master"), S("frog")));
}
-
- SECTION("set found") {
- REQUIRE_SUCCESS(memcached_set_by_key(memc, S("master"), S("frog"), S("frog"), 0, 0));
- REQUIRE_SUCCESS(memcached_exist_by_key(memc, S("master"), S("frog")));
-
- SECTION("deleted not found") {
- REQUIRE_SUCCESS(memcached_delete_by_key(memc, S("master"), S("frog"), 0));
- REQUIRE_RC(MEMCACHED_NOTFOUND, memcached_exist_by_key(memc, S("master"), S("frog")));
- }
- }
}
}
#include "test/lib/common.hpp"
#include "test/lib/MemcachedCluster.hpp"
-#include "testing/fixtures/ketama.hpp"
+#include "test/fixtures/ketama.hpp"
#include "libmemcached/continuum.hpp"
#include "libmemcached/instance.hpp"
--- /dev/null
+#include "test/lib/common.hpp"
+#include "test/lib/MemcachedCluster.hpp"
+
+#include "libmemcached/options.hpp"
+#include "libmemcached/common.h"
+#include "libmemcached/array.h"
+
+
+#include <libgen.h>
+
+#define FIXTURES_OPTIONS_CONFIG "/../../fixtures/options.config"
+
+TEST_CASE("memcached_options") {
+ MemcachedPtr memc;
+ LoneReturnMatcher test{*memc};
+
+ char cpp_file[] = __FILE__, buf[1024], *dir = dirname(cpp_file);
+ auto file = string(dir) + FIXTURES_OPTIONS_CONFIG;
+ auto config = "--CONFIGURE-FILE=\"" + file + "\"";
+
+ REQUIRE_RC(MEMCACHED_INVALID_ARGUMENTS, memcached_parse_configure_file(**memc, nullptr, 123));
+ REQUIRE_RC(MEMCACHED_INVALID_ARGUMENTS, memcached_parse_configure_file(**memc, file.c_str(), 0));
+ REQUIRE_RC(MEMCACHED_ERRNO, memcached_parse_configure_file(**memc, S("foobar.baz")));
+ REQUIRE_SUCCESS(memcached_parse_configure_file(**memc, file.c_str(), file.length()));
+
+ REQUIRE_SUCCESS(libmemcached_check_configuration(config.c_str(), config.length(), buf, sizeof(buf) - 1));
+ REQUIRE_RC(MEMCACHED_PARSE_ERROR, libmemcached_check_configuration(S("foo bar"), nullptr, 0));
+}
--- /dev/null
+#include "test/lib/common.hpp"
+
+#define NULL_CSTR nullptr,0
+
+TEST_CASE("memcached_regression_lp854604") {
+ char buffer[1024];
+
+ REQUIRE(MEMCACHED_INVALID_ARGUMENTS == libmemcached_check_configuration(NULL_CSTR, NULL_CSTR));
+ REQUIRE(MEMCACHED_INVALID_ARGUMENTS == libmemcached_check_configuration(NULL_CSTR, buffer, 0));
+ for (auto i = 0; i < 100; ++i) {
+ REQUIRE(MEMCACHED_PARSE_ERROR == libmemcached_check_configuration(S("syntax error"), buffer, random_num(0,1024)));
+ }
+}
--- /dev/null
+#include "test/lib/common.hpp"
+#include "test/lib/MemcachedCluster.hpp"
+
+static memcached_return_t item_counter(const memcached_instance_st *, const char *key, size_t, const char *value, size_t, void *context)
+{
+ if (key == "curr_items"s) {
+ auto counter = static_cast<size_t *>(context);
+ *counter += stoul(value);
+ }
+
+ return MEMCACHED_SUCCESS;
+}
+
+TEST_CASE("memcached_stat") {
+ MemcachedCluster test;
+ auto memc = &test.memc;
+
+ SECTION("invalid arguments") {
+ size_t count = 0;
+ REQUIRE_RC(MEMCACHED_INVALID_ARGUMENTS, memcached_stat_execute(memc, "BAD_ARG", item_counter, &count));
+ }
+
+ SECTION("execute") {
+ for (auto i = 0; i < 64; ++i) {
+ auto key = random_ascii_string(32);
+ REQUIRE_SUCCESS(memcached_set(memc, key.c_str(), key.length(), nullptr, 0, 0, 0));
+ }
+
+ memcached_quit(memc);
+
+ size_t count = 0;
+ REQUIRE_SUCCESS(memcached_stat_execute(memc, nullptr, item_counter, &count));
+ REQUIRE(count == 64);
+ }
+
+ SECTION("servername") {
+ for (auto &server : test.cluster.getServers()) {
+ auto port = server.getSocketOrPort();
+ if (holds_alternative<int>(port)) {
+ memcached_stat_st stats;
+ REQUIRE_SUCCESS(memcached_stat_servername(&stats, nullptr, "localhost", get<int>(port)));
+ REQUIRE(stats.pid);
+ }
+ }
+ }
+
+ SECTION("get_keys/get_value") { // oh my
+ memcached_return_t rc;
+ auto servers = test.cluster.getServers();
+ Malloced stats(memcached_stat(memc, nullptr, &rc));
+ Malloced keys(memcached_stat_get_keys(memc, nullptr, nullptr));
+
+ REQUIRE_SUCCESS(rc);
+ REQUIRE(*stats);
+ REQUIRE(*keys);
+
+ for (auto i = 0U; i < memcached_server_count(memc); ++i) {
+ auto this_stat = &(*stats)[i];
+
+ for (auto key = *keys; *key; ++key) {
+ Malloced val(memcached_stat_get_value(memc, this_stat, *key, &rc));
+ REQUIRE_SUCCESS(rc);
+ REQUIRE(*val);
+ }
+ for (auto &server : test.cluster.getServers()) {
+ if (this_stat->pid == server.getPid()) {
+ goto found;
+ }
+ }
+
+ FAIL("no server matches pid " << this_stat->pid);
+ found:;
+ }
+ }
+}
return TEST_SUCCESS;
}
-/* Do not copy the style of this code, I just access hosts to testthis function */
-test_return_t stats_servername_test(memcached_st *memc)
-{
- memcached_stat_st memc_stat;
- const memcached_instance_st * instance=
- memcached_server_instance_by_position(memc, 0);
-
- if (LIBMEMCACHED_WITH_SASL_SUPPORT and memcached_get_sasl_callbacks(memc))
- {
- return TEST_SKIPPED;
- }
-
- test_compare(MEMCACHED_SUCCESS, memcached_stat_servername(&memc_stat, NULL,
- memcached_server_name(instance),
- memcached_server_port(instance)));
-
- return TEST_SUCCESS;
-}
-
test_return_t mget_result_test(memcached_st *memc)
{
const char *keys[]= {"fudge", "son", "food"};
return TEST_SUCCESS;
}
-
-test_return_t get_stats_keys(memcached_st *memc)
-{
- char **stat_list;
- char **ptr;
- memcached_stat_st memc_stat;
- memcached_return_t rc;
-
- stat_list= memcached_stat_get_keys(memc, &memc_stat, &rc);
- test_compare(MEMCACHED_SUCCESS, rc);
- for (ptr= stat_list; *ptr; ptr++)
- test_true(*ptr);
-
- free(stat_list);
-
- return TEST_SUCCESS;
-}
-
-
-test_return_t get_stats(memcached_st *memc)
-{
- memcached_return_t rc;
-
- memcached_stat_st *memc_stat= memcached_stat(memc, NULL, &rc);
- test_compare(MEMCACHED_SUCCESS, rc);
- test_true(memc_stat);
-
- for (uint32_t x= 0; x < memcached_server_count(memc); x++)
- {
- char **stat_list= memcached_stat_get_keys(memc, memc_stat+x, &rc);
- test_compare(MEMCACHED_SUCCESS, rc);
- for (char **ptr= stat_list; *ptr; ptr++) {};
-
- free(stat_list);
- }
-
- memcached_stat_free(NULL, memc_stat);
-
- return TEST_SUCCESS;
-}
-
test_return_t memcached_fetch_result_NOT_FOUND(memcached_st *memc)
{
memcached_return_t rc;
}
-test_return_t add_host_test1(memcached_st *memc)
-{
- memcached_return_t rc;
- char servername[]= "0.example.com";
-
- memcached_server_st *servers= memcached_server_list_append_with_weight(NULL, servername, 400, 0, &rc);
- test_true(servers);
- test_compare(1U, memcached_server_list_count(servers));
-
- for (uint32_t x= 2; x < 20; x++)
- {
- char buffer[SMALL_STRING_LEN];
-
- snprintf(buffer, SMALL_STRING_LEN, "%lu.example.com", (unsigned long)(400 +x));
- servers= memcached_server_list_append_with_weight(servers, buffer, 401, 0,
- &rc);
- test_compare(MEMCACHED_SUCCESS, rc);
- test_compare(x, memcached_server_list_count(servers));
- }
-
- test_compare(MEMCACHED_SUCCESS, memcached_server_push(memc, servers));
- test_compare(MEMCACHED_SUCCESS, memcached_server_push(memc, servers));
-
- memcached_server_list_free(servers);
-
- return TEST_SUCCESS;
-}
-
-
static void my_free(const memcached_st *ptr, void *mem, void *context)
{
(void)context;
return TEST_SUCCESS;
}
-test_return_t enable_consistent_crc(memcached_st *memc)
-{
- test_compare(MEMCACHED_SUCCESS, memcached_behavior_set(memc, MEMCACHED_BEHAVIOR_DISTRIBUTION, MEMCACHED_DISTRIBUTION_CONSISTENT));
- test_compare(memcached_behavior_get(memc, MEMCACHED_BEHAVIOR_DISTRIBUTION), uint64_t(MEMCACHED_DISTRIBUTION_CONSISTENT));
-
- test_return_t rc;
- if ((rc= pre_crc(memc)) != TEST_SUCCESS)
- {
- return rc;
- }
-
- test_compare(memcached_behavior_get(memc, MEMCACHED_BEHAVIOR_DISTRIBUTION), uint64_t(MEMCACHED_DISTRIBUTION_CONSISTENT));
-
- if (memcached_behavior_get(memc, MEMCACHED_BEHAVIOR_HASH) != MEMCACHED_HASH_CRC)
- {
- return TEST_SKIPPED;
- }
-
- return TEST_SUCCESS;
-}
-
-test_return_t enable_consistent_hsieh(memcached_st *memc)
-{
- test_return_t rc;
- memcached_behavior_set(memc, MEMCACHED_BEHAVIOR_DISTRIBUTION, MEMCACHED_DISTRIBUTION_CONSISTENT);
- if ((rc= pre_hsieh(memc)) != TEST_SUCCESS)
- {
- return rc;
- }
-
- test_compare(memcached_behavior_get(memc, MEMCACHED_BEHAVIOR_DISTRIBUTION), uint64_t(MEMCACHED_DISTRIBUTION_CONSISTENT));
-
- if (memcached_behavior_get(memc, MEMCACHED_BEHAVIOR_HASH) != MEMCACHED_HASH_HSIEH)
- {
- return TEST_SKIPPED;
- }
-
- return TEST_SUCCESS;
-}
-
-test_return_t enable_cas(memcached_st *memc)
-{
- if (libmemcached_util_version_check(memc, 1, 2, 4))
- {
- memcached_behavior_set(memc, MEMCACHED_BEHAVIOR_SUPPORT_CAS, true);
-
- return TEST_SUCCESS;
- }
-
- return TEST_SKIPPED;
-}
-
-test_return_t check_for_1_2_3(memcached_st *memc)
-{
- memcached_version(memc);
-
- const memcached_instance_st * instance=
- memcached_server_instance_by_position(memc, 0);
-
- if ((instance->major_version >= 1 && (instance->minor_version == 2 && instance->micro_version >= 4))
- or instance->minor_version > 2)
- {
- return TEST_SUCCESS;
- }
-
- return TEST_SKIPPED;
-}
-
test_return_t MEMCACHED_BEHAVIOR_POLL_TIMEOUT_test(memcached_st *memc)
{
const uint64_t timeout= 100; // Not using, just checking that it sets
+++ /dev/null
-/* vim:expandtab:shiftwidth=2:tabstop=2:smarttab:
- *
- * Libmemcached Client and Server
- *
- * Copyright (C) 2011 Data Differential, http://datadifferential.com/
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are
- * met:
- *
- * * Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * * Redistributions in binary form must reproduce the above
- * copyright notice, this list of conditions and the following disclaimer
- * in the documentation and/or other materials provided with the
- * distribution.
- *
- * * The names of its contributors may not be used to endorse or
- * promote products derived from this software without specific prior
- * written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
- * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- *
- */
-
-#include "mem_config.h"
-#include "libtest/test.hpp"
-
-using namespace libtest;
-
-#include "libmemcached-1.0/memcached.h"
-
-#include "tests/namespace.h"
-
-test_return_t memcached_increment_namespace(memcached_st *memc)
-{
- uint64_t new_number;
-
- test_compare(MEMCACHED_SUCCESS,
- memcached_set(memc,
- test_literal_param("number"),
- test_literal_param("0"),
- (time_t)0, (uint32_t)0));
-
- test_compare(MEMCACHED_SUCCESS,
- memcached_increment(memc,
- test_literal_param("number"),
- 1, &new_number));
- test_compare(uint64_t(1), new_number);
-
- test_compare(MEMCACHED_SUCCESS,
- memcached_increment(memc,
- test_literal_param("number"),
- 1, &new_number));
- test_compare(uint64_t(2), new_number);
-
- memcached_st *clone= memcached_clone(NULL, memc);
-
- test_compare(MEMCACHED_SUCCESS,
- memcached_callback_set(clone, MEMCACHED_CALLBACK_NAMESPACE, "all_your_bases"));
-
- test_compare(MEMCACHED_NOTFOUND,
- memcached_increment(clone,
- test_literal_param("number"),
- 1, &new_number));
-
- test_compare(MEMCACHED_SUCCESS,
- memcached_add(clone,
- test_literal_param("number"),
- test_literal_param("10"),
- (time_t)0, (uint32_t)0));
-
- char *value= memcached_get(clone,
- test_literal_param("number"),
- 0, 0, 0);
- test_true(value);
- test_compare(2UL, strlen(value));
- test_strcmp("10", value);
- free(value);
-
- test_compare(MEMCACHED_SUCCESS,
- memcached_increment(clone,
- test_literal_param("number"),
- 1, &new_number));
- test_compare(uint64_t(11), new_number);
-
- test_compare(MEMCACHED_SUCCESS,
- memcached_increment(memc,
- test_literal_param("number"),
- 1, &new_number));
- test_compare(uint64_t(3), new_number);
-
- memcached_free(clone);
-
- return TEST_SUCCESS;
-}
-
+++ /dev/null
-/* vim:expandtab:shiftwidth=2:tabstop=2:smarttab:
- *
- * Libmemcached library
- *
- * Copyright (C) 2012 Data Differential, http://datadifferential.com/
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are
- * met:
- *
- * * Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * * Redistributions in binary form must reproduce the above
- * copyright notice, this list of conditions and the following disclaimer
- * in the documentation and/or other materials provided with the
- * distribution.
- *
- * * The names of its contributors may not be used to endorse or
- * promote products derived from this software without specific prior
- * written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
- * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- *
- */
-
-#include "mem_config.h"
-
-#include <cstdlib>
-#include <climits>
-
-#include "libtest/test.hpp"
-
-#include "libmemcached-1.0/memcached.h"
-#include "libmemcachedutil-1.0/util.h"
-
-using namespace libtest;
-
-#include "tests/libmemcached-1.0/stat.h"
-
-static memcached_return_t item_counter(const memcached_instance_st * ,
- const char *key, size_t key_length,
- const char *value, size_t, // value_length,
- void *context)
-{
- if ((key_length == (sizeof("curr_items") -1)) and (strncmp("curr_items", key, (sizeof("curr_items") -1)) == 0))
- {
- uint64_t* counter= (uint64_t*)context;
- unsigned long number_value= strtoul(value, (char **)NULL, 10);
- ASSERT_NEQ(number_value, ULONG_MAX);
- *counter= *counter +number_value;
- }
-
- return MEMCACHED_SUCCESS;
-}
-
-test_return_t memcached_stat_TEST(memcached_st *memc)
-{
- uint64_t counter= 0;
- test_compare(MEMCACHED_INVALID_ARGUMENTS,
- memcached_stat_execute(memc, "BAD_ARG_VALUE", item_counter, &counter));
-
- return TEST_SUCCESS;
-}
-
-#define memcached_dump_TEST2_COUNT 64
-test_return_t memcached_stat_TEST2(memcached_st *memc)
-{
- test_skip(false, memcached_behavior_get(memc, MEMCACHED_BEHAVIOR_BINARY_PROTOCOL));
-
- /* The dump test relies on there being at least 32 items in memcached */
- for (uint32_t x= 0; x < memcached_dump_TEST2_COUNT; x++)
- {
- char key[1024];
- int length= snprintf(key, sizeof(key), "%s%u", __func__, x);
-
- ASSERT_TRUE(length > 0);
-
- test_compare(MEMCACHED_SUCCESS,
- memcached_set(memc, key, length,
- NULL, 0, // Zero length values
- time_t(0), uint32_t(0)));
- }
- memcached_quit(memc);
-
- uint64_t counter= 0;
- ASSERT_EQ(MEMCACHED_SUCCESS,
- memcached_stat_execute(memc, NULL, item_counter, &counter));
- ASSERT_TRUE(counter);
-
- return TEST_SUCCESS;
-}
+++ /dev/null
-/* vim:expandtab:shiftwidth=2:tabstop=2:smarttab:
- *
- * Libmemcached library
- *
- * Copyright (C) 2012 Data Differential, http://datadifferential.com/
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions are
- * met:
- *
- * * Redistributions of source code must retain the above copyright
- * notice, this list of conditions and the following disclaimer.
- *
- * * Redistributions in binary form must reproduce the above
- * copyright notice, this list of conditions and the following disclaimer
- * in the documentation and/or other materials provided with the
- * distribution.
- *
- * * The names of its contributors may not be used to endorse or
- * promote products derived from this software without specific prior
- * written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
- * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
- * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
- * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- *
- */
-
-#pragma once
-
-test_return_t memcached_stat_TEST(memcached_st *);
-test_return_t memcached_stat_TEST2(memcached_st *);