X-Git-Url: https://git.octo.it/?a=blobdiff_plain;f=t%2Fdiff-lib.sh;h=745a1b03116a58f89cc9ac533f948fa91c795518;hb=e52290428b5b6f55cb7bb7a4624751750241d5aa;hp=a912f435aa67d7b2cde09f0b8c9855442c6c2377;hpb=d59a6043a8a7aed97c684fb4f14fe5221df1fcaf;p=git.git diff --git a/t/diff-lib.sh b/t/diff-lib.sh index a912f435..745a1b03 100755 --- a/t/diff-lib.sh +++ b/t/diff-lib.sh @@ -29,7 +29,13 @@ compare_diff_raw_z () { compare_diff_patch () { # When heuristics are improved, the score numbers would change. # Ignore them while comparing. - sed -e '/^[dis]*imilarity index [0-9]*%$/d' <"$1" >.tmp-1 - sed -e '/^[dis]*imilarity index [0-9]*%$/d' <"$2" >.tmp-2 + sed -e ' + /^[dis]*imilarity index [0-9]*%$/d + /^index [0-9a-f]*\.\.[0-9a-f]/d + ' <"$1" >.tmp-1 + sed -e ' + /^[dis]*imilarity index [0-9]*%$/d + /^index [0-9a-f]*\.\.[0-9a-f]/d + ' <"$2" >.tmp-2 diff -u .tmp-1 .tmp-2 && rm -f .tmp-1 .tmp-2 }