Interplane page as plain text, for reading tools and agents. English is the reference text: translate it with your own tool. Text in backticks and in ``` blocks (commands, fingerprints, file names) and link targets in <...> are exact: copy them, never translate them. Page: /drakestapleton/git/blob/master/t/t5535-fetch-push-symref.sh # git [Ported from github.com/git/git] Sync with Git 2.56.1 Brought by drakestapleton Sign in to star 0 stars 0 watching About Files History Releases Proposed changes Issues For developers branch `master` Branches Tags History `git / t / t5535-fetch-push-symref.sh` 42 lines ยท 1049 bytes Raw Blame History 1 #!/bin/sh 2 3 test_description='avoiding conflicting update through symref aliasing' 4 5 . ./test-lib.sh 6 7 test_expect_success 'setup' ' 8 test_commit one && 9 git clone . src && 10 git clone src dst1 && 11 git clone src dst2 && 12 test_commit two && 13 ( cd src && git pull ) 14 ' 15 16 test_expect_success 'push' ' 17 ( 18 cd src && 19 git push ../dst1 "refs/remotes/*:refs/remotes/*" 20 ) && 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 27 ' 28 29 test_expect_success 'fetch' ' 30 ( 31 cd dst2 && 32 git fetch ../src "refs/remotes/*:refs/remotes/*" 33 ) && 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 40 ' 41 42 test_done