From: Johannes Sixt <j6t@kdbg•org>
To: Siddharth Shrimali <r.siddharth.shrimali@gmail•com>
Cc: peff@peff•net, git@vger•kernel.org
Subject: Re: [PATCH] t3700: avoid suppressing git's exit code
Date: Sat, 28 Feb 2026 09:12:46 +0100 [thread overview]
Message-ID: <3c854150-2efc-4f5b-8a75-bb40808babd0@kdbg.org> (raw)
In-Reply-To: <20260227165143.70188-1-r.siddharth.shrimali@gmail.com>
Am 27.02.26 um 17:51 schrieb Siddharth Shrimali:
> @@ -536,9 +544,9 @@ test_expect_success 'all statuses changed in folder if . is given' '
> touch x y z sub/a sub/dir/b &&
> git add -A &&
> git add --chmod=+x . &&
> - test $(git ls-files --stage | grep ^100644 | wc -l) -eq 0 &&
> + test $(git ls-files --stage >actual && grep ^100644 actual | wc -l) -eq 0 &&
> git add --chmod=-x . &&
> - test $(git ls-files --stage | grep ^100755 | wc -l) -eq 0
> + test $(git ls-files --stage >actual && grep ^100755 actual | wc -l) -eq 0
This doesn't help. The exit code of $( ) that is substituted into a
command is ignored, too. You must move the git invocation out of the
subshell.
> )
> '
>
> @@ -574,4 +582,4 @@ test_expect_success CASE_INSENSITIVE_FS 'path is case-insensitive' '
> git add "$downcased"
> '
>
> -test_done
> +test_done
> \ No newline at end of file
Please keep the newline at the end of file.
-- Hannes
next prev parent reply other threads:[~2026-02-28 8:12 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-02-27 16:51 [PATCH] t3700: avoid suppressing git's exit code Siddharth Shrimali
2026-02-27 18:19 ` Junio C Hamano
2026-02-28 7:00 ` [PATCH v2] t3700: avoid hidden failures and use test_grep helper Siddharth Shrimali
2026-03-02 21:24 ` Junio C Hamano
2026-02-28 8:12 ` Johannes Sixt [this message]
2026-02-28 10:15 ` [PATCH] t3700: avoid suppressing git's exit code Siddharth Shrimali
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=3c854150-2efc-4f5b-8a75-bb40808babd0@kdbg.org \
--to=j6t@kdbg$(echo .)org \
--cc=git@vger$(echo .)kernel.org \
--cc=peff@peff$(echo .)net \
--cc=r.siddharth.shrimali@gmail$(echo .)com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox