t/t3430: avoid undefined git diff behavior
The autosquash-and-exec test used "git diff HEAD^!" to mean "git diff HEAD^ HEAD". Use these directly instead of relying on the undefined but actual-current behavior of "HEAD^!". Signed-off-by: Chris Torek <chris.torek@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Chris Torek committed
Jun 9, 2020 at 19:00 UTC
bafa2d741e9dcc4d70ffcb3943e530635bb8e684
1 file changed
+1
-1
t/t3430-rebase-merges.sh
+1
-1
@@ -420,7 +420,7 @@ test_expect_success 'with --autosquash and --exec' '
420
git commit --fixup B B.t &&
421
write_script show.sh <<-\EOF &&
422
subject="$(git show -s --format=%s HEAD)"
423
- content="$(git diff HEAD^! | tail -n 1)"
423
+ content="$(git diff HEAD^ HEAD | tail -n 1)"
424
echo "$subject: $content"
425
EOF
426
test_tick &&