3 test_description
='diff hunk header truncation'
5 TEST_PASSES_SANITIZE_LEAK
=true
11 NS
="$N$N$N$N$N$N$N$N$N$N$N$N$N"
13 test_expect_success setup
'
17 printf " %s\n" B C D E F G H I J K &&
19 printf " %s\n" M N O P Q R S T U V
23 sed -e "/^ [EP]/s/$/ modified/" <file >file+ &&
28 test_expect_success
'hunk header truncation with an overly long line' '
30 git diff | sed -n -e "s/^.*@@//p" >actual &&
32 echo " A $N$N$N$N$N$N$N$N$N2" &&
33 echo " L $N$N$N$N$N$N$N$N$N1"
35 test_cmp expected actual