t6501: use 'git gc' in quiet mode

t6501-freshen-objects.sh sends the standard error from 'git gc' to a file and verifies that it is empty. This is intended as a way to ensure no warnings are written during the operation. However, as the commit-graph is added as a step to 'git gc', its progress will appear in the output. Pass the '-q' argument to avoid a failing test case when progress is written. Signed-off-by: Derrick Stolee <dstolee@microsoft.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Derrick Stolee committed Aug 13, 2019 at 11:37 UTC b068d9a250246896cc56b9450049b2ed6451ccbb
1 file changed +3 -3
t/t6501-freshen-objects.sh
+3 -3
@@ -137,7 +137,7 @@ test_expect_success 'do not complain about existing broken links (commit)' '
137 some message
138 EOF
139 commit=$(git hash-object -t commit -w broken-commit) &&
140 - git gc 2>stderr &&
140 + git gc -q 2>stderr &&
141 verbose git cat-file -e $commit &&
142 test_must_be_empty stderr
143 '
@@ -147,7 +147,7 @@ test_expect_success 'do not complain about existing broken links (tree)' '
147 100644 blob 0000000000000000000000000000000000000003 foo
148 EOF
149 tree=$(git mktree --missing <broken-tree) &&
150 - git gc 2>stderr &&
150 + git gc -q 2>stderr &&
151 git cat-file -e $tree &&
152 test_must_be_empty stderr
153 '
@@ -162,7 +162,7 @@ test_expect_success 'do not complain about existing broken links (tag)' '
162 this is a broken tag
163 EOF
164 tag=$(git hash-object -t tag -w broken-tag) &&
165 - git gc 2>stderr &&
165 + git gc -q 2>stderr &&
166 git cat-file -e $tag &&
167 test_must_be_empty stderr
168 '