* [GSoC PATCH] t6101: avoid suppressing git's exit code
@ 2026-03-28 13:59 Trieu Huynh
0 siblings, 0 replies; only message in thread
From: Trieu Huynh @ 2026-03-28 13:59 UTC (permalink / raw)
To: git; +Cc: Trieu Huynh
Update t6101-rev-parse-parents.sh to redirect git-rev-parse
output to a temporary file instead of piping it directly to
not hide the exit code of git commands behind pipes, as a
crash in git might go unnoticed.
Signed-off-by: Trieu Huynh <vikingtc4@gmail.com>
---
t/t6101-rev-parse-parents.sh | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/t/t6101-rev-parse-parents.sh b/t/t6101-rev-parse-parents.sh
index 5f55ab98d3..7281889717 100755
--- a/t/t6101-rev-parse-parents.sh
+++ b/t/t6101-rev-parse-parents.sh
@@ -39,7 +39,8 @@ test_expect_success 'setup' '
'
test_expect_success 'start is valid' '
- git rev-parse start | grep "^$OID_REGEX$"
+ git rev-parse start >actual &&
+ test_grep "^$OID_REGEX$" actual
'
test_expect_success 'start^0' '
--
2.43.0
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2026-03-28 13:59 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-03-28 13:59 [GSoC PATCH] t6101: avoid suppressing git's exit code Trieu Huynh
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox