Andrew's git
/
gitweb.git
/ diff
summary
|
log
|
commit
| diff |
tree
commit
grep
author
committer
pickaxe
?
re
t/helper: merge test-read-cache into test-tool
author
Nguyễn Thái Ngọc Duy
<pclouds@gmail.com>
Sat, 24 Mar 2018 07:44:51 +0000
(08:44 +0100)
committer
Junio C Hamano
<gitster@pobox.com>
Tue, 27 Mar 2018 15:45:47 +0000
(08:45 -0700)
Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Makefile
patch
|
blob
|
history
t/helper/test-read-cache.c
patch
|
blob
|
history
t/helper/test-tool.c
patch
|
blob
|
history
t/helper/test-tool.h
patch
|
blob
|
history
t/perf/p0002-read-cache.sh
patch
|
blob
|
history
raw
|
patch
|
inline
| side by side (parent:
15b7581
)
diff --git
a/Makefile
b/Makefile
index 076c7784947d98c4b5715bc1799f12c6ce29cd79..393fb9aca4b73f1b2236cacb0a41aa5d0fba3751 100644
(file)
--- a/
Makefile
+++ b/
Makefile
@@
-671,6
+671,7
@@
TEST_BUILTINS_OBJS += test-mktemp.o
TEST_BUILTINS_OBJS += test-online-cpus.o
TEST_BUILTINS_OBJS += test-path-utils.o
TEST_BUILTINS_OBJS += test-prio-queue.o
TEST_BUILTINS_OBJS += test-online-cpus.o
TEST_BUILTINS_OBJS += test-path-utils.o
TEST_BUILTINS_OBJS += test-prio-queue.o
+TEST_BUILTINS_OBJS += test-read-cache.o
TEST_BUILTINS_OBJS += test-sha1.o
TEST_PROGRAMS_NEED_X += test-dump-fsmonitor
TEST_BUILTINS_OBJS += test-sha1.o
TEST_PROGRAMS_NEED_X += test-dump-fsmonitor
@@
-678,7
+679,6
@@
TEST_PROGRAMS_NEED_X += test-dump-untracked-cache
TEST_PROGRAMS_NEED_X += test-fake-ssh
TEST_PROGRAMS_NEED_X += test-line-buffer
TEST_PROGRAMS_NEED_X += test-parse-options
TEST_PROGRAMS_NEED_X += test-fake-ssh
TEST_PROGRAMS_NEED_X += test-line-buffer
TEST_PROGRAMS_NEED_X += test-parse-options
-TEST_PROGRAMS_NEED_X += test-read-cache
TEST_PROGRAMS_NEED_X += test-write-cache
TEST_PROGRAMS_NEED_X += test-ref-store
TEST_PROGRAMS_NEED_X += test-regex
TEST_PROGRAMS_NEED_X += test-write-cache
TEST_PROGRAMS_NEED_X += test-ref-store
TEST_PROGRAMS_NEED_X += test-regex
diff --git
a/t/helper/test-read-cache.c
b/t/helper/test-read-cache.c
index 48255eef31a1e83d9a2bbb01670ba089a11c91f8..d674c88ba092d60366a14eaeccc9f4bc6f32660c 100644
(file)
--- a/
t/helper/test-read-cache.c
+++ b/
t/helper/test-read-cache.c
@@
-1,6
+1,7
@@
+#include "test-tool.h"
#include "cache.h"
#include "cache.h"
-int cmd_
main
(int argc, const char **argv)
+int cmd_
_read_cache
(int argc, const char **argv)
{
int i, cnt = 1;
if (argc == 2)
{
int i, cnt = 1;
if (argc == 2)
diff --git
a/t/helper/test-tool.c
b/t/helper/test-tool.c
index 64af0bbe94f1661436ba0de176c67a49008a0c04..5bea2164629f88984dc247cba7d50e218e6fbd2e 100644
(file)
--- a/
t/helper/test-tool.c
+++ b/
t/helper/test-tool.c
@@
-26,6
+26,7
@@
static struct test_cmd cmds[] = {
{ "online-cpus", cmd__online_cpus },
{ "path-utils", cmd__path_utils },
{ "prio-queue", cmd__prio_queue },
{ "online-cpus", cmd__online_cpus },
{ "path-utils", cmd__path_utils },
{ "prio-queue", cmd__prio_queue },
+ { "read-cache", cmd__read_cache },
{ "sha1", cmd__sha1 },
};
{ "sha1", cmd__sha1 },
};
diff --git
a/t/helper/test-tool.h
b/t/helper/test-tool.h
index 900c96dc0274045cdfbda09c47059327c795219f..4d51c17f5a2bad98c464987e7aec2bf25ad250ef 100644
(file)
--- a/
t/helper/test-tool.h
+++ b/
t/helper/test-tool.h
@@
-20,6
+20,7
@@
int cmd__mktemp(int argc, const char **argv);
int cmd__online_cpus(int argc, const char **argv);
int cmd__path_utils(int argc, const char **argv);
int cmd__prio_queue(int argc, const char **argv);
int cmd__online_cpus(int argc, const char **argv);
int cmd__path_utils(int argc, const char **argv);
int cmd__prio_queue(int argc, const char **argv);
+int cmd__read_cache(int argc, const char **argv);
int cmd__sha1(int argc, const char **argv);
#endif
int cmd__sha1(int argc, const char **argv);
#endif
diff --git
a/t/perf/p0002-read-cache.sh
b/t/perf/p0002-read-cache.sh
index 9180ae9343a03824653e087aaa766b9d33e50a94..cdd105a5945239850a12479ff1138a5428e3b6d6 100755
(executable)
--- a/
t/perf/p0002-read-cache.sh
+++ b/
t/perf/p0002-read-cache.sh
@@
-8,7
+8,7
@@
test_perf_default_repo
count=1000
test_perf "read_cache/discard_cache $count times" "
count=1000
test_perf "read_cache/discard_cache $count times" "
- test-read-cache $count
+ test-
tool
read-cache $count
"
test_done
"
test_done