From e6faf9e26bcb172026a4984ecadbaa8b6789bcb7 Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Mon, 4 Feb 2013 12:39:09 +0000 Subject: tests: "wc -l" portability for *BSDs On FreeBSD 9.0, "wc -l" emits leading whitespace, so filter it through tr -d '[:space:]' to eliminate it. --- t/t0030-fast-pipe-response.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 't/t0030-fast-pipe-response.sh') diff --git a/t/t0030-fast-pipe-response.sh b/t/t0030-fast-pipe-response.sh index aab4357..e91392a 100755 --- a/t/t0030-fast-pipe-response.sh +++ b/t/t0030-fast-pipe-response.sh @@ -35,7 +35,7 @@ t_begin "send three keep-alive requests" && { } t_begin "ensure responses were all keep-alive" && { - test 3 -eq $(grep '< Connection: keep-alive' < $err | wc -l) + test 3 -eq $(grep '< Connection: keep-alive' < $err | count_lines) } t_begin "HTTP/1.0 test" && { -- cgit v1.2.3-24-ge0c7