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/chainlint/chain-break-return-exit.test # 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 / chainlint / chain-break-return-exit.test` 25 lines ยท 701 bytes Raw Blame History 1 test_expect_success 'chain-break-return-exit' ' 2 case "$(git ls-files)" in 3 one) echo pass one ;; 4 # LINT: broken &&-chain okay if explicit "return 1" signals failuire 5 *) echo bad one; return 1 ;; 6 esac && 7 ( 8 case "$(git ls-files)" in 9 two) echo pass two ;; 10 # LINT: broken &&-chain okay if explicit "exit 1" signals failuire 11 *) echo bad two; exit 1 ;; 12 esac 13 ) && 14 case "$(git ls-files)" in 15 dir/two"$LF"one) echo pass both ;; 16 # LINT: broken &&-chain okay if explicit "return 1" signals failuire 17 *) echo bad; return 1 ;; 18 esac && 19 20 for i in 1 2 3 4 ; do 21 # LINT: broken &&-chain okay if explicit "return $?" signals failure 22 git checkout main -b $i || return $? 23 test_commit $i $i $i tag$i || return $? 24 done 25 '