t1512: ignore whitespaces in wc -l output
Some implementations of sed (e.g. MacOS X) have whitespaces in the output of "wc -l" that reads from the standard input. Ignore these whitespaces by not quoting the command substitution to be compared with the constant "16". Signed-off-by: Junio C Hamano <gitster@pobox.com>maint
parent
957d74062c
commit
4c654f5f27
|
@ -257,7 +257,7 @@ test_expect_success 'rev-parse --disambiguate' '
|
|||
# commits created by commit-tree in earlier tests do not share
|
||||
# the prefix.
|
||||
git rev-parse --disambiguate=000000000 >actual &&
|
||||
test "$(wc -l <actual)" = 16 &&
|
||||
test $(wc -l <actual) = 16 &&
|
||||
test "$(sed -e "s/^\(.........\).*/\1/" actual | sort -u)" = 000000000
|
||||
'
|
||||
|
||||
|
|
Loading…
Reference in New Issue