t5318: use 'test_must_be_empty'
A handful of tests in t5318 use 'test_line_count = 0 ...' to make sure that some command does not write any output. While correct, it is more idiomatic to use 'test_must_be_empty' instead. Switch the former invocations to use the latter instead. Signed-off-by: Taylor Blau <me@ttaylorr.com> Acked-by: Derrick Stolee <dstolee@microsoft.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Taylor Blau committed
Jun 3, 2020 at 16:21 UTC
6334c5ff9732c4b2171ce3aee012196c01cdf401
1 file changed
+4
-4
t/t5318-commit-graph.sh
+4
-4
@@ -140,7 +140,7 @@ test_expect_success 'Add more commits' '
140
test_expect_success 'commit-graph write progress off for redirected stderr' '
141
cd "$TRASH_DIRECTORY/full" &&
142
git commit-graph write 2>err &&
143
- test_line_count = 0 err
143
+ test_must_be_empty err
144
'
145
146
test_expect_success 'commit-graph write force progress on for stderr' '
@@ -152,13 +152,13 @@ test_expect_success 'commit-graph write force progress on for stderr' '
152
test_expect_success 'commit-graph write with the --no-progress option' '
153
cd "$TRASH_DIRECTORY/full" &&
154
git commit-graph write --no-progress 2>err &&
155
- test_line_count = 0 err
155
+ test_must_be_empty err
156
'
157
158
test_expect_success 'commit-graph verify progress off for redirected stderr' '
159
cd "$TRASH_DIRECTORY/full" &&
160
git commit-graph verify 2>err &&
161
- test_line_count = 0 err
161
+ test_must_be_empty err
162
'
163
164
test_expect_success 'commit-graph verify force progress on for stderr' '
@@ -170,7 +170,7 @@ test_expect_success 'commit-graph verify force progress on for stderr' '
170
test_expect_success 'commit-graph verify with the --no-progress option' '
171
cd "$TRASH_DIRECTORY/full" &&
172
git commit-graph verify --no-progress 2>err &&
173
- test_line_count = 0 err
173
+ test_must_be_empty err
174
'
175
176
# Current graph structure: