3 test_description
='compression setting of fast-import utility'
5 TEST_PASSES_SANITIZE_LEAK
=true
12 printf "%2000000s
\n" "$
*"
14 ) | git "$@
" fast-import
17 while read expect config
19 test_expect_success "fast-import
(packed
) with
$config" '
20 test_when_finished "rm -f .git
/objects
/pack
/pack-
*.
*" &&
21 test_when_finished "rm -rf .git
/objects
/??
" &&
22 import_large -c fastimport.unpacklimit=0 $config &&
23 sz=$(test_file_size .git/objects/pack/pack-*.pack) &&
25 small) test "$sz" -le 100000 ;;
26 large) test "$sz" -ge 100000 ;;
30 large -c core.compression=0
31 small -c core.compression=9
32 large -c core.compression=0 -c pack.compression=0
33 large -c core.compression=9 -c pack.compression=0
34 small -c core.compression=0 -c pack.compression=9
35 small -c core.compression=9 -c pack.compression=9
36 large -c pack.compression=0
37 small -c pack.compression=9
40 while read expect config
42 test_expect_success "fast-import
(loose
) with
$config" '
43 test_when_finished "rm -f .git
/objects
/pack
/pack-
*.
*" &&
44 test_when_finished "rm -rf .git
/objects
/??
" &&
45 import_large -c fastimport.unpacklimit=9 $config &&
46 sz=$(test_file_size .git/objects/??/????*) &&
48 small) test "$sz" -le 100000 ;;
49 large) test "$sz" -ge 100000 ;;
53 large -c core.compression=0
54 small -c core.compression=9
55 large -c core.compression=0 -c core.loosecompression=0
56 large -c core.compression=9 -c core.loosecompression=0
57 small -c core.compression=0 -c core.loosecompression=9
58 small -c core.compression=9 -c core.loosecompression=9
59 large -c core.loosecompression=0
60 small -c core.loosecompression=9