Skip to content

Commit 6946e52

Browse files
bk2204gitster
authored andcommitted
t/helper/test-dump-split-index: initialize git repository
In this test helper, we read the index. In order to have the proper hash algorithm set up, we must call setup_git_directory. Do so, so that the test works when extensions.objectFormat is set. Signed-off-by: brian m. carlson <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 8bd5a29 commit 6946e52

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

t/helper/test-dump-split-index.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,8 @@ int cmd__dump_split_index(int ac, const char **av)
1313
struct split_index *si;
1414
int i;
1515

16+
setup_git_directory();
17+
1618
do_read_index(&the_index, av[1], 1);
1719
printf("own %s\n", oid_to_hex(&the_index.oid));
1820
si = the_index.split_index;

0 commit comments

Comments
 (0)