projects
/
m6w6
/
libmemcached
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
|
github
raw
|
inline
| side by side
docs: sanitize
[m6w6/libmemcached]
/
tests
/
libmemcached-1.0
/
mem_functions.cc
diff --git
a/tests/libmemcached-1.0/mem_functions.cc
b/tests/libmemcached-1.0/mem_functions.cc
index 0e380b7a0cfa0e0845b10fd0f73ec6f170170e70..23dea417f02b11530f7b00517f0b3a56498b7579 100644
(file)
--- a/
tests/libmemcached-1.0/mem_functions.cc
+++ b/
tests/libmemcached-1.0/mem_functions.cc
@@
-35,8
+35,8
@@
*
*/
*
*/
-#include
<mem_config.h>
-#include
<libtest/test.hpp>
+#include
"mem_config.h"
+#include
"libtest/test.hpp"
#if defined(HAVE_LIBUUID) && HAVE_LIBUUID
# include <uuid/uuid.h>
#if defined(HAVE_LIBUUID) && HAVE_LIBUUID
# include <uuid/uuid.h>
@@
-46,13
+46,13
@@
Test cases
*/
Test cases
*/
-#include
<libmemcached-1.0/memcached.h>
+#include
"libmemcached-1.0/memcached.h"
#include "libmemcached/is.h"
#include "libmemcached/server_instance.h"
#include "libmemcached/is.h"
#include "libmemcached/server_instance.h"
-#include
<libhashkit-1.0/hashkit.h>
+#include
"libhashkit-1.0/hashkit.h"
-#include
<libtest/memcached.hpp>
+#include
"libtest/memcached.hpp"
#include <cerrno>
#include <memory>
#include <cerrno>
#include <memory>
@@
-66,17
+66,17
@@
#include <iostream>
#include <iostream>
-#include
<libtest/server.h>
+#include
"libtest/server.h"
-#include "
clients
/generator.h"
+#include "
bin
/generator.h"
#define SMALL_STRING_LEN 1024
#define SMALL_STRING_LEN 1024
-#include
<libtest/test.hpp>
+#include
"libtest/test.hpp"
using namespace libtest;
using namespace libtest;
-#include
<libmemcachedutil-1.0/util.h>
+#include
"libmemcachedutil-1.0/util.h"
#include "tests/hash_results.h"
#include "tests/hash_results.h"
@@
-717,7
+717,7
@@
test_return_t cas_test(memcached_st *memc)
test_compare(MEMCACHED_SUCCESS, memcached_flush(memc, 0));
test_compare(MEMCACHED_SUCCESS, memcached_flush(memc, 0));
- test_
skip(true
, memcached_behavior_set(memc, MEMCACHED_BEHAVIOR_SUPPORT_CAS, true));
+ test_
compare(MEMCACHED_SUCCESS
, memcached_behavior_set(memc, MEMCACHED_BEHAVIOR_SUPPORT_CAS, true));
test_compare(MEMCACHED_SUCCESS,
memcached_set(memc,
test_compare(MEMCACHED_SUCCESS,
memcached_set(memc,
@@
-1880,8
+1880,8
@@
test_return_t block_add_regression(memcached_st *memc)
Error << memcached_last_error_message(memc);
return TEST_SKIPPED;
}
Error << memcached_last_error_message(memc);
return TEST_SKIPPED;
}
- test_compare(
*memc, MEMCACHED_SUCCESS
);
- test_compare(
rc, MEMCACHED_SUCCESS
);
+ test_compare(
MEMCACHED_SUCCESS,*memc
);
+ test_compare(
MEMCACHED_SUCCESS, rc
);
}
return TEST_SUCCESS;
}
return TEST_SUCCESS;
@@
-4462,7
+4462,7
@@
test_return_t test_multiple_get_last_disconnect(memcached_st *)
test_return_t test_verbosity(memcached_st *memc)
{
test_return_t test_verbosity(memcached_st *memc)
{
-
memcached_verbosity(memc, 3
);
+
test_compare(MEMCACHED_SUCCESS, memcached_verbosity(memc, 0)
);
return TEST_SUCCESS;
}
return TEST_SUCCESS;
}
@@
-5083,7
+5083,11
@@
test_return_t kill_HUP_TEST(memcached_st *original_memc)
test_literal_param(__func__), // Keys
test_literal_param(__func__), // Values
0, 0);
test_literal_param(__func__), // Keys
test_literal_param(__func__), // Values
0, 0);
- test_compare(MEMCACHED_CONNECTION_FAILURE, ret);
+ if (ret == MEMCACHED_ERRNO) {
+ test_compare(EPIPE, memcached_last_error_errno(memc));
+ } else {
+ test_compare(MEMCACHED_CONNECTION_FAILURE, ret);
+ }
memcached_free(memc);
memcached_free(memc);