From: Denton Liu Date: Fri, 15 Nov 2019 01:01:30 GMT Subject: [PATCH 26/27] t9902: disable pipefail Message-ID: <95806f55e7e0ad1ac187ea162a74d5883fa86e67.1573779466.git.liu.denton@gmail.com> In-Reply-To: In a future patch, we plan on running tests with `set -o pipefail`. However, these tests cannot run with pipefail. Since git-completion.bash is not a testing script, it does not follow the same return code conventions and it's expected that commands can fail within a pipeline. Run `set +o pipefail` to disable pipefail in this script. Note that this is being unconditionally run because this test will be skipped if its not running on Bash. Signed-off-by: Denton Liu --- t/t9902-completion.sh | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/t/t9902-completion.sh b/t/t9902-completion.sh index e90ac565e1..75a512669e 100755 --- a/t/t9902-completion.sh +++ b/t/t9902-completion.sh @@ -7,6 +7,12 @@ test_description='test bash completion' . ./lib-bash.sh +# These tests cannot run with pipefail. Since git-completion.bash is not +# a testing script, it does not follow the same return code conventions +# and it's expected that commands can fail within a pipeline. Ignore +# these failures. +set +o pipefail + complete () { # do nothing -- 2.24.0.399.gf8350c9437