Sync with 'maint'
[alt-git.git] / t / t5327-multi-pack-bitmaps-rev.sh
blob994a8e6be464ac08982e806874fdc865ec3ab078
1 #!/bin/sh
3 test_description='exercise basic multi-pack bitmap functionality (.rev files)'
5 TEST_PASSES_SANITIZE_LEAK=true
6 . ./test-lib.sh
7 . "${TEST_DIRECTORY}/lib-bitmap.sh"
9 # We'll be writing our own MIDX, so avoid getting confused by the automatic
10 # ones.
11 GIT_TEST_MULTI_PACK_INDEX=0
12 GIT_TEST_MULTI_PACK_INDEX_WRITE_INCREMENTAL=0
14 # Unlike t5326, this test exercise multi-pack bitmap functionality where the
15 # object order is stored in a separate .rev file.
16 GIT_TEST_MIDX_WRITE_REV=1
17 GIT_TEST_MIDX_READ_RIDX=0
18 export GIT_TEST_MIDX_WRITE_REV
19 export GIT_TEST_MIDX_READ_RIDX
21 test_midx_bitmap_rev () {
22 writeLookupTable=false
24 for i in "$@"
26 case $i in
27 "pack.writeBitmapLookupTable") writeLookupTable=true;;
28 esac
29 done
31 test_expect_success 'setup bitmap config' '
32 rm -rf * .git &&
33 git init &&
34 git config pack.writeBitmapLookupTable '"$writeLookupTable"'
37 midx_bitmap_core rev
38 midx_bitmap_partial_tests rev
41 test_midx_bitmap_rev
42 test_midx_bitmap_rev "pack.writeBitmapLookupTable"
44 test_done