summaryrefslogtreecommitdiff
path: root/t/chainlint/nested-here-doc.expect
diff options
context:
space:
mode:
authorLibravatar Eric Sunshine <sunshine@sunshineco.com>2021-12-13 01:30:57 -0500
committerLibravatar Junio C Hamano <gitster@pobox.com>2021-12-13 14:15:29 -0800
commit34ba05c2966f9e96b74ea984251e3bda802d6a7a (patch)
tree4c50e731fb7f441242b6d6b5a4f8582889450d6f /t/chainlint/nested-here-doc.expect
parentchainlint.sed: don't mistake `<< word` in string as here-doc operator (diff)
downloadtgif-34ba05c2966f9e96b74ea984251e3bda802d6a7a.tar.xz
chainlint.sed: stop throwing away here-doc tags
The purpose of chainlint is to highlight problems it finds in test code by inserting annotations at the location of each problem. Arbitrarily eliding bits of the code it is checking is not helpful, yet this is exactly what chainlint.sed does by cavalierly and unnecessarily dropping the here-doc operator and tag; i.e. `cat <<TAG` becomes simply `cat` in the output. This behavior can make it more difficult for the test writer to align the annotated output of chainlint.sed with the original test code. Address this by retaining here-doc tags. Signed-off-by: Eric Sunshine <sunshine@sunshineco.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/chainlint/nested-here-doc.expect')
-rw-r--r--t/chainlint/nested-here-doc.expect6
1 files changed, 3 insertions, 3 deletions
diff --git a/t/chainlint/nested-here-doc.expect b/t/chainlint/nested-here-doc.expect
index 2a51205d32..e3bef63f75 100644
--- a/t/chainlint/nested-here-doc.expect
+++ b/t/chainlint/nested-here-doc.expect
@@ -1,7 +1,7 @@
-cat >foop &&
+cat <<ARBITRARY >foop &&
(
- cat &&
- cat ?!AMP?!
+ cat <<-INPUT_END &&
+ cat <<-EOT ?!AMP?!
foobar
)