chainlint.pl: don't require `&` background command to end with `&&`
commitaabc3258a1da5f06e0b2492f450d4b8e7e8137e5
authorEric Sunshine <sunshine@sunshineco.com>
Thu, 1 Sep 2022 00:29:47 +0000 (1 00:29 +0000)
committerJunio C Hamano <gitster@pobox.com>
Thu, 1 Sep 2022 17:07:40 +0000 (1 10:07 -0700)
treeab283dec966538e1050a0da387b02fa69d68492d
parentd00113ec3474a1652a73c11695c7e7b5182d80a7
chainlint.pl: don't require `&` background command to end with `&&`

The exit status of the `&` asynchronous operator which starts a command
in the background is unconditionally zero, and the few places in the
test scripts which launch commands asynchronously are not interested in
the exit status of the `&` operator (though they often capture the
background command's PID). As such, there is little value in complaining
about broken &&-chain for a command launched in the background, and
doing so would only make busy-work for test authors. Therefore, take
this special case into account when checking for &&-chain breakage.

Signed-off-by: Eric Sunshine <sunshine@sunshineco.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t/chainlint.pl
t/chainlint/chain-break-background.expect [new file with mode: 0644]
t/chainlint/chain-break-background.test [new file with mode: 0644]