t: use update-ref and show-ref to reading/writing refs
Reading and writing .git/refs/* assumes that refs are stored in the 'files' ref backend. Signed-off-by: Han-Wen Nienhuys <hanwen@google.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
committed by
Junio C Hamano
parent
d1eb22da09
commit
cdb73ca56f
@ -135,7 +135,7 @@ test_expect_success 'tag replaced commit' '
|
||||
test_expect_success '"git fsck" works' '
|
||||
git fsck master >fsck_master.out &&
|
||||
test_i18ngrep "dangling commit $R" fsck_master.out &&
|
||||
test_i18ngrep "dangling tag $(cat .git/refs/tags/mytag)" fsck_master.out &&
|
||||
test_i18ngrep "dangling tag $(git show-ref -s refs/tags/mytag)" fsck_master.out &&
|
||||
test -z "$(git fsck)"
|
||||
'
|
||||
|
||||
|
||||
Reference in New Issue
Block a user