tests: modernise style: more uses of test_line_count
Prefer: test_line_count <OP> COUNT FILE over: test $(wc -l <FILE) <OP> COUNT (or similar usages) in several tests. Signed-off-by: Stefano Lattarini <stefano.lattarini@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:

committed by
Junio C Hamano

parent
e8dde3e5f9
commit
3fb0459bc8
@ -476,14 +476,14 @@ test_expect_success 'cvs status' '
|
||||
cd cvswork &&
|
||||
GIT_CONFIG="$git_config" cvs update &&
|
||||
GIT_CONFIG="$git_config" cvs status | grep "^File: status.file" >../out &&
|
||||
test $(wc -l <../out) = 2
|
||||
test_line_count = 2 ../out
|
||||
'
|
||||
|
||||
cd "$WORKDIR"
|
||||
test_expect_success 'cvs status (nonrecursive)' '
|
||||
cd cvswork &&
|
||||
GIT_CONFIG="$git_config" cvs status -l | grep "^File: status.file" >../out &&
|
||||
test $(wc -l <../out) = 1
|
||||
test_line_count = 1 ../out
|
||||
'
|
||||
|
||||
cd "$WORKDIR"
|
||||
|
Reference in New Issue
Block a user