Re: [PATCH] t3070: make chain lint tester happy
From: Eric Sunshine <hidden>
Date: 2023-03-25 08:06:54
On Sat, Mar 25, 2023 at 3:58 AM Jeff King [off-list ref] wrote:
On Sat, Mar 25, 2023 at 02:54:45AM -0400, Eric Sunshine wrote:quoted
I am unable to reproduce any linting errors when running this script through chainlint, which is why I was more than a little confused by this patch when I read it, and I was just about to ask for more information, such as the actual error message.It's not your chain-lint script, but rather the builtin one that sticks "(exit 117) &&" in front of the snippet and evals it. So it creates the exact "foo && bar &" situation by prepending a line to the snippet.
Thanks for clarifying that. I failed to infer that from the commit message.
So running (on seen, which has 1f2e05f0b79):
./t3070-wildmatch.sh
gives me:
ok 1890 - ipathmatch (via ls-files): match '[Z-y]' 'Z'
error: bug in the test script: broken &&-chain or run-away HERE-DOC:
test-tool wildmatch wildmatch \
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaab \
"*a*a*a*a*a*a*a*a*a*a*a*a*a*a*a*a" &
pid=$! &&
sleep 2 &&
! kill $!Yes, I can reproduce it now. My mistake was that I tested 'seen' rather than 1f2e05f0b79, not realizing that Junio had already applied Michael's patch. (I meant to check if it had been applied, but forgot to do so.)