diff options
author | Stepan Kasal <kasal@ucw.cz> | 2014-06-04 17:57:52 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2014-06-04 11:14:25 -0700 |
commit | b93e6e36637bed9d80f9ffa786ea78044fde6bac (patch) | |
tree | 09d99c7e31d8f19cbba35c2682060f5f22f2b0b2 /t/t5003-archive-zip.sh | |
parent | e156455ea49124c140a67623f22a393db62d5d98 (diff) | |
download | git-b93e6e36637bed9d80f9ffa786ea78044fde6bac.tar.gz |
t5000, t5003: do not use test_cmp to compare binary filessk/test-cmp-bin
test_cmp() is primarily meant to compare text files (and display the
difference for debug purposes).
Raw "cmp" is better suited to compare binary files (tar, zip, etc.).
On MinGW, test_cmp is a shell function mingw_test_cmp that tries to
read both files into environment, stripping CR characters (introduced
in commit 4d715ac0).
This function usually speeds things up, as fork is extremly slow on
Windows. But no wonder that this function is extremely slow and
sometimes even crashes when comparing large tar or zip files.
Signed-off-by: Stepan Kasal <kasal@ucw.cz>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t5003-archive-zip.sh')
-rwxr-xr-x | t/t5003-archive-zip.sh | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/t/t5003-archive-zip.sh b/t/t5003-archive-zip.sh index c72f71eb18..21a5c93f41 100755 --- a/t/t5003-archive-zip.sh +++ b/t/t5003-archive-zip.sh @@ -97,15 +97,15 @@ test_expect_success \ test_expect_success \ 'git archive --format=zip vs. the same in a bare repo' \ - 'test_cmp d.zip d1.zip' + 'test_cmp_bin d.zip d1.zip' test_expect_success 'git archive --format=zip with --output' \ 'git archive --format=zip --output=d2.zip HEAD && - test_cmp d.zip d2.zip' + test_cmp_bin d.zip d2.zip' test_expect_success 'git archive with --output, inferring format' ' git archive --output=d3.zip HEAD && - test_cmp d.zip d3.zip + test_cmp_bin d.zip d3.zip ' test_expect_success \ |