diff options
Diffstat (limited to 't/helper/test-read-cache.c')
-rw-r--r-- | t/helper/test-read-cache.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/t/helper/test-read-cache.c b/t/helper/test-read-cache.c index b736ef1642..c1ae276395 100644 --- a/t/helper/test-read-cache.c +++ b/t/helper/test-read-cache.c @@ -1,6 +1,10 @@ +#define USE_THE_INDEX_VARIABLE #include "test-tool.h" #include "cache.h" #include "config.h" +#include "repository.h" +#include "setup.h" +#include "wrapper.h" int cmd__read_cache(int argc, const char **argv) { @@ -20,7 +24,7 @@ int cmd__read_cache(int argc, const char **argv) git_config(git_default_config, NULL); for (i = 0; i < cnt; i++) { - read_cache(); + repo_read_index(the_repository); if (name) { int pos; @@ -33,7 +37,7 @@ int cmd__read_cache(int argc, const char **argv) ce_uptodate(the_index.cache[pos]) ? "" : " not"); write_file(name, "%d\n", i); } - discard_cache(); + discard_index(&the_index); } return 0; } |