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/t2014-checkout-switch.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 / t2014-checkout-switch.sh` 29 lines ยท 446 bytes Raw Blame History 1 #!/bin/sh 2 3 test_description='Peter MacMillan' 4 5 . ./test-lib.sh 6 7 test_expect_success setup ' 8 echo Hello >file && 9 git add file && 10 test_tick && 11 git commit -m V1 && 12 echo Hello world >file && 13 git add file && 14 git checkout -b other 15 ' 16 17 test_expect_success 'check all changes are staged' ' 18 git diff --exit-code 19 ' 20 21 test_expect_success 'second commit' ' 22 git commit -m V2 23 ' 24 25 test_expect_success 'check' ' 26 git diff --cached --exit-code 27 ' 28 29 test_done