t5523-push-upstream: add function to ensure fresh upstream repo
Signed-off-by: Tay Ray Chuan <rctay89@gmail.com> Reviewed-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
parent
e674c17db2
commit
2d59ced104
@ -3,8 +3,12 @@
|
|||||||
test_description='push with --set-upstream'
|
test_description='push with --set-upstream'
|
||||||
. ./test-lib.sh
|
. ./test-lib.sh
|
||||||
|
|
||||||
|
ensure_fresh_upstream() {
|
||||||
|
rm -rf parent && git init --bare parent
|
||||||
|
}
|
||||||
|
|
||||||
test_expect_success 'setup bare parent' '
|
test_expect_success 'setup bare parent' '
|
||||||
git init --bare parent &&
|
ensure_fresh_upstream &&
|
||||||
git remote add upstream parent
|
git remote add upstream parent
|
||||||
'
|
'
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user