diff options
author | Edward Thomson <ethomson@edwardthomson.com> | 2022-01-22 17:34:36 -0500 |
---|---|---|
committer | Edward Thomson <ethomson@edwardthomson.com> | 2022-01-23 09:48:20 -0500 |
commit | 69ca594bafd438fea419b1ebe757a9d13da4d254 (patch) | |
tree | b7b760bb90311ee4cd511d697d54c1ff8a1d97a8 /tests/pack/packbuilder.c | |
parent | 55eb096b93d4e658bfc0d19270b56f00dff9ec0d (diff) | |
download | libgit2-ethomson/oid_cleanups.tar.gz |
packbuilder: use the packfile name instead of hashethomson/oid_cleanups
Deprecate the `git_packfile_hash` function. Callers should use the new
`git_packfile_name` function which provides a unique packfile name.
Diffstat (limited to 'tests/pack/packbuilder.c')
-rw-r--r-- | tests/pack/packbuilder.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/tests/pack/packbuilder.c b/tests/pack/packbuilder.c index 73bc6674b..f23579817 100644 --- a/tests/pack/packbuilder.c +++ b/tests/pack/packbuilder.c @@ -138,16 +138,12 @@ void test_pack_packbuilder__create_pack(void) cl_assert_equal_s(hex, "5d410bdf97cf896f9007681b92868471d636954b"); } -void test_pack_packbuilder__get_hash(void) +void test_pack_packbuilder__get_name(void) { - char hex[GIT_OID_HEXSZ+1]; hex[GIT_OID_HEXSZ] = '\0'; - seed_packbuilder(); cl_git_pass(git_packbuilder_write(_packbuilder, ".", 0, NULL, NULL)); - git_oid_fmt(hex, git_packbuilder_hash(_packbuilder)); - - cl_assert_equal_s(hex, "7f5fa362c664d68ba7221259be1cbd187434b2f0"); + cl_assert_equal_s("7f5fa362c664d68ba7221259be1cbd187434b2f0", git_packbuilder_name(_packbuilder)); } void test_pack_packbuilder__write_default_path(void) |