From b6baa1deacc15196103d3474e5b23e79c11bec93 Mon Sep 17 00:00:00 2001 From: Date: Fri, 2 May 2008 09:35:02 -0700 Subject: [PATCH] Adding in more tests for command line tools. --- clients/Makefile.am | 24 +++++++++++++++++++++++- clients/utilities.c | 2 +- 2 files changed, 24 insertions(+), 2 deletions(-) diff --git a/clients/Makefile.am b/clients/Makefile.am index 0dbec9f3..23debed1 100644 --- a/clients/Makefile.am +++ b/clients/Makefile.am @@ -28,7 +28,6 @@ memflush_SOURCES = memflush.c utilities.c memflush_LDADD = $(LDADDS) memflush_LDFLAGS = -rpath $(pkglibdir) - memerror_SOURCES = memerror.c utilities.c memerror_LDADD = $(LDADDS) memerror_LDFLAGS = -rpath $(pkglibdir) @@ -36,3 +35,26 @@ memerror_LDFLAGS = -rpath $(pkglibdir) memslap_SOURCES = memslap.c utilities.c generator.c execute.c memslap_LDADD = $(LDADDS) -lpthread memslap_LDFLAGS = -rpath $(pkglibdir) + +test-start-server: + memflush --servers=localhost + memcp --servers=localhost /etc/services + memcat --servers=localhost /etc/services + memrm --servers=localhost /etc/services + memstat --servers=localhost + memslap --servers=localhost + memslap --servers=localhost --concurrency=10 + memslap --servers=localhost --concurrency=10 --initial-load=1000 + memslap --servers=localhost --concurrency=10 --initial-load=1000 --execute-number=10 + memslap --servers=localhost --concurrency=10 --initial-load=1000 --execute-number=10 --test=get + memslap --servers=localhost --concurrency=10 --initial-load=1000 --execute-number=10 --test=set + memslap --servers=localhost --concurrency=10 --initial-load=1000 --execute-number=10 --test=set --non-blocking + +valgrind: + libtool --mode=execute valgrind --leak-check=yes --show-reachable=yes memslap --servers=localhost + libtool --mode=execute valgrind --leak-check=yes --show-reachable=yes memslap --servers=localhost --concurrency=10 + libtool --mode=execute valgrind --leak-check=yes --show-reachable=yes memslap --servers=localhost --concurrency=10 --initial-load=1000 + libtool --mode=execute valgrind --leak-check=yes --show-reachable=yes memslap --servers=localhost --concurrency=10 --initial-load=1000 --execute-number=10 + libtool --mode=execute valgrind --leak-check=yes --show-reachable=yes memslap --servers=localhost --concurrency=10 --initial-load=1000 --execute-number=10 --test=get + libtool --mode=execute valgrind --leak-check=yes --show-reachable=yes memslap --servers=localhost --concurrency=10 --initial-load=1000 --execute-number=10 --test=set + libtool --mode=execute valgrind --leak-check=yes --show-reachable=yes memslap --servers=localhost --concurrency=10 --initial-load=1000 --execute-number=10 --test=set --non-blocking diff --git a/clients/utilities.c b/clients/utilities.c index c845ed1a..b5755ee1 100644 --- a/clients/utilities.c +++ b/clients/utilities.c @@ -37,7 +37,7 @@ char *lookup_help(memcached_options option) case OPT_ADD: return("Use add command with memcached when storing."); case OPT_SLAP_EXECUTE_NUMBER: return("Number of times to execute the given test."); case OPT_SLAP_INITIAL_LOAD: return("Number of key pairs to load before executing tests."); - case OPT_SLAP_TEST: return("Test to run."); + case OPT_SLAP_TEST: return("Test to run (currently \"get\" or \"set\")."); case OPT_SLAP_CONCURRENCY: return("Number of users to simulate with load."); case OPT_SLAP_NON_BLOCK: return("Set TCP up to use non-blocking IO."); case OPT_SLAP_TCP_NODELAY: return("Set TCP socket up to use nodelay."); -- 2.30.2