3 # Copyright (c) 2008 Dmitry V. Levin
6 test_description
='fetch exit status test'
8 GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
=main
9 export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
11 TEST_PASSES_SANITIZE_LEAK
=true
14 test_expect_success setup
'
18 git commit -m initial &&
20 git checkout -b side &&
22 git commit -a -m side &&
29 test_expect_success
'non-fast-forward fetch' '
31 test_must_fail git fetch . main:side
35 test_expect_success
'forced update' '
37 git fetch . +main:side