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/t0055-beyond-symlinks.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 / t0055-beyond-symlinks.sh` 35 lines ยท 597 bytes Raw Blame History 1 #!/bin/sh 2 3 test_description='update-index and add refuse to add beyond symlinks' 4 5 . ./test-lib.sh 6 7 test_expect_success SYMLINKS setup ' 8 >a && 9 mkdir b && 10 ln -s b c && 11 >c/d && 12 git update-index --add a b/d 13 ' 14 15 test_expect_success SYMLINKS 'update-index --add beyond symlinks' ' 16 test_must_fail git update-index --add c/d && 17 cat >expect <<-\EOF && 18 a 19 b/d 20 EOF 21 git ls-files >actual && 22 test_cmp expect actual 23 ' 24 25 test_expect_success SYMLINKS 'add beyond symlinks' ' 26 test_must_fail git add c/d && 27 cat >expect <<-\EOF && 28 a 29 b/d 30 EOF 31 git ls-files >actual && 32 test_cmp expect actual 33 ' 34 35 test_done