diff options
author | Jonathan Nieder <jrnieder@gmail.com> | 2013-03-18 16:13:41 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2013-03-19 11:07:26 -0700 |
commit | 848575d833ca0d9d47db372348576f3b98bd19b7 (patch) | |
tree | a81b6e6eb516e60ad9955978bcbdcaa1535879f2 /builtin/commit.c | |
parent | push test: use test_config when appropriate (diff) | |
download | tgif-848575d833ca0d9d47db372348576f3b98bd19b7.tar.xz |
push test: simplify check of push result
This test checks each ref with code like the following:
r=$(git show-ref -s --verify refs/$ref) &&
test "z$r" = "z$the_first_commit"
Afterward it counts refs:
test 1 = $(git for-each-ref refs/remotes/origin | wc -l)
Simpler to test the number and values of relevant refs in for-each-ref
output at the same time using test_cmp. This makes the test more
readable and provides more helpful "./t5516-push-push.sh -v" output
when the test fails.
Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/commit.c')
0 files changed, 0 insertions, 0 deletions