summaryrefslogtreecommitdiff
path: root/commit.h
diff options
context:
space:
mode:
authorJeff King <peff@peff.net>2024-07-10 04:39:31 -0400
committerJunio C Hamano <gitster@pobox.com>2024-07-10 10:14:23 -0700
commitf6b75726b2779faa57bd590deb882d3da157f3be (patch)
treea849b3cd688bd616be98f645fa4ea136d7f2fe10 /commit.h
parent1d133ae91f7dd5cc6ccd0137a175372460383235 (diff)
t: convert some here-doc test bodies
The t1404 script checks a lot of output from Git which contains single quotes. Because the test snippets are themselves wrapped in the same single-quotes, we have to resort to using $SQ to match them. This is error-prone and makes the tests harder to read. Instead, let's use the new here-doc feature added in the previous commit, which lets us write anything in the test body we want (except the here-doc end marker on a line by itself, of course). Note that we do use "\" in our marker to avoid interpolation (which is the whole point). But we don't use "<<-", as we want to preserve whitespace in the snippet (and running with "-v" before and after shows that we produce the exact same output, except with the ugly $SQ references fixed). I just converted every test here, even though only some of them use $SQ. But it would be equally correct to mix-and-match styles if we don't mind the inconsistency. I've also converted a few tests in t0600 which were moved from t1404 (I had written this patch before they were moved, but it seemed worth porting over the changes rather than losing them). Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'commit.h')
0 files changed, 0 insertions, 0 deletions