subtree test: simplify preparation of expected results
commit6a8ad880f02e8399c2fcb4aec0d42fb6e4287ebb
authorJonathan Nieder <jrnieder@gmail.com>
Mon, 30 Jul 2018 19:07:38 +0000 (30 12:07 -0700)
committerJunio C Hamano <gitster@pobox.com>
Mon, 30 Jul 2018 20:58:16 +0000 (30 13:58 -0700)
treefc9c39e5550ecb560fcf5481aa7a07cbc9cb1b20
parentad6eee36ba1b5fa8f5b837edf12f3a84313ee021
subtree test: simplify preparation of expected results

This mixture of quoting, pipes, and here-docs to produce expected
results in shell variables is difficult to follow.  Simplify by using
simpler constructs that write output to files instead.

Noticed because without this patch, t/chainlint is not able to
understand the script in order to validate that its subshells use an
unbroken &&-chain, causing "make -C contrib/subtree test" to fail with

error: bug in the test script: broken &&-chain or run-away HERE-DOC:

in t7900.21.

Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
contrib/subtree/t/t7900-subtree.sh