From 7885faf18b776eaed4a7ddcf8fb8bce699820eea Mon Sep 17 00:00:00 2001 From: luhuachao <14054766+chimney-lee@users.noreply.github.com> Date: Wed, 2 Dec 2020 19:17:25 +0800 Subject: [PATCH] Modify help msg PING_BULK to PING_MBULK in benchmark (#8109) As described in redis-benchamrk help message 'The test names are the same as the ones produced as output.', In redis-benchmark output, we can only see PING_BULK, but the cmd `redis-benchmark -t ping_bulk` is not supported. We have to run it with ping_mbulk which is not user friendly. --- src/redis-benchmark.c | 2 +- tests/integration/redis-benchmark.tcl | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/redis-benchmark.c b/src/redis-benchmark.c index 0ec9cb1eb..d8c62daa3 100644 --- a/src/redis-benchmark.c +++ b/src/redis-benchmark.c @@ -1829,7 +1829,7 @@ int main(int argc, const char **argv) { if (test_is_selected("ping_mbulk") || test_is_selected("ping")) { len = redisFormatCommand(&cmd,"PING"); - benchmark("PING_BULK",cmd,len); + benchmark("PING_MBULK",cmd,len); free(cmd); } diff --git a/tests/integration/redis-benchmark.tcl b/tests/integration/redis-benchmark.tcl index 4a4be2ebc..5a4f09952 100644 --- a/tests/integration/redis-benchmark.tcl +++ b/tests/integration/redis-benchmark.tcl @@ -33,7 +33,7 @@ start_server {tags {"benchmark"}} { puts [colorstr red "redis-benchmark non zero code. first line: $first_line"] fail "redis-benchmark non zero code. first line: $first_line" } - # ping total calls are 2*issued commands per test due to PING_INLINE and PING_BULK + # ping total calls are 2*issued commands per test due to PING_INLINE and PING_MBULK assert_match {*calls=200,*} [cmdstat ping] assert_match {*calls=100,*} [cmdstat set] assert_match {*calls=100,*} [cmdstat get]