]> git.ipfire.org Git - thirdparty/git.git/blob - t/t5513-fetch-track.sh
Merge git-gui into ml/git-gui-exec-path-fix
[thirdparty/git.git] / t / t5513-fetch-track.sh
1 #!/bin/sh
2
3 test_description='fetch follows remote-tracking branches correctly'
4
5 TEST_PASSES_SANITIZE_LEAK=true
6 . ./test-lib.sh
7
8 test_expect_success setup '
9 >file &&
10 git add . &&
11 test_tick &&
12 git commit -m Initial &&
13 git branch b-0 &&
14 git branch b1 &&
15 git branch b/one &&
16 test_create_repo other &&
17 (
18 cd other &&
19 git config remote.origin.url .. &&
20 git config remote.origin.fetch "+refs/heads/b/*:refs/remotes/b/*"
21 )
22 '
23
24 test_expect_success fetch '
25 (
26 cd other && git fetch origin &&
27 test "$(git for-each-ref --format="%(refname)")" = refs/remotes/b/one
28 )
29 '
30
31 test_done