]> git.ipfire.org Git - thirdparty/git.git/blame - t/perf/p0007-write-cache.sh
Merge branch 'ma/header-dup-cleanup'
[thirdparty/git.git] / t / perf / p0007-write-cache.sh
CommitLineData
3921a0b3
KW
1#!/bin/sh
2
3test_description="Tests performance of writing the index"
4
5. ./perf-lib.sh
6
7test_perf_default_repo
8
9test_expect_success "setup repo" '
10 if git rev-parse --verify refs/heads/p0006-ballast^{commit}
11 then
74d2f569
ES
12 echo Assuming synthetic repo from many-files.sh &&
13 git config --local core.sparsecheckout 1 &&
3921a0b3
KW
14 cat >.git/info/sparse-checkout <<-EOF
15 /*
16 !ballast/*
17 EOF
18 else
19 echo Assuming non-synthetic repo...
20 fi &&
21 nr_files=$(git ls-files | wc -l)
22'
23
24count=3
25test_perf "write_locked_index $count times ($nr_files files)" "
c81f843d 26 test-tool write-cache $count
3921a0b3
KW
27"
28
29test_done