3 test_description='avoiding conflicting update through symref aliasing'
7 test_expect_success 'setup' '
13 ( cd src && git pull )
16 test_expect_success 'push' '
19 git push ../dst1 "refs/remotes/*:refs/remotes/*"
21 git ls-remote src "refs/remotes/*" >expect &&
22 git ls-remote dst1 "refs/remotes/*" >actual &&
23 test_cmp expect actual &&
24 ( cd src && git symbolic-ref refs/remotes/origin/HEAD ) >expect &&
25 ( cd dst1 && git symbolic-ref refs/remotes/origin/HEAD ) >actual &&
26 test_cmp expect actual
29 test_expect_success 'fetch' '
32 git fetch ../src "refs/remotes/*:refs/remotes/*"
34 git ls-remote src "refs/remotes/*" >expect &&
35 git ls-remote dst2 "refs/remotes/*" >actual &&
36 test_cmp expect actual &&
37 ( cd src && git symbolic-ref refs/remotes/origin/HEAD ) >expect &&
38 ( cd dst2 && git symbolic-ref refs/remotes/origin/HEAD ) >actual &&
39 test_cmp expect actual