Skip to content

Commit 3f97f1b

Browse files
ttaylorrgitster
authored andcommitted
t/perf: use 'test_file_size' in more places
The perf test suite prefers to use test_file_size over 'wc -c' when inside of a test_size block. One advantage is that accidentally writign "wc -c file" (instead of "wc -c <file") does not inadvertently break the tests (since the former will include the filename in the output of wc). Both of the two uses of test_size use "wc -c", but let's convert those to the more conventional test_file_size helper instead. Signed-off-by: Taylor Blau <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 46698a8 commit 3f97f1b

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

t/perf/p5311-pack-bitmaps-fetch.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ test_fetch_bitmaps () {
3939
'
4040

4141
test_size "size $title" '
42-
wc -c <tmp.pack
42+
test_file_size tmp.pack
4343
'
4444

4545
test_perf "client $title (lookup=$1)" '

t/perf/p5332-multi-pack-reuse.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ do
7373
"
7474

7575
test_size "clone size for $nr_packs-pack scenario ($reuse-pack reuse)" '
76-
wc -c <result
76+
test_file_size result
7777
'
7878
done
7979
done

0 commit comments

Comments
 (0)