t4124: only mark git command with test_must_fail
authorDenton Liu <liu.denton@gmail.com>
Tue, 7 Jan 2020 04:53:13 +0000 (23:53 -0500)
committerJunio C Hamano <gitster@pobox.com>
Mon, 27 Jan 2020 20:56:02 +0000 (12:56 -0800)
commit37a63faae58aee5cd2dd9806d2e98c9ad998a7e5
tree35946abb75fd55bdb053061d671d971643377215
parenta8c663cf65ae1e40c90bfd4a1dd3e8d1826eafbe
t4124: only mark git command with test_must_fail

The test_must_fail function should only be used for git commands since
we should assume that external commands work sanely. Since apply_patch
wraps a sed and git invocation, rewrite it to accept an `!` argument
which would cause only the git command to be prefixed with
`test_must_fail`.

Signed-off-by: Denton Liu <liu.denton@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t/t4124-apply-ws-rule.sh