From a07e26bf367075d7b31f3f180b65605412b0624b Mon Sep 17 00:00:00 2001 From: YAMAMOTO Takashi Date: Wed, 1 Oct 2014 14:00:36 +0900 Subject: [PATCH] ovs-vswitchd.at: Fix "start additional ovs-vswitchd process" test NetBSD implementation of wc command outputs extra whitespaces like the following. Tweak the test to success on such environments. % echo hoge|wc -l|hexdump -C 00000000 20 20 20 20 20 20 20 31 0a | 1.| 00000009 % The failing test was introduced by commit 6bef3c7ca859f208239ca61ec3b25c09a3571553 ("bridge: Fix high cpu utilization.") Signed-off-by: YAMAMOTO Takashi Acked-by: Joe Stringer --- tests/ovs-vswitchd.at | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/tests/ovs-vswitchd.at b/tests/ovs-vswitchd.at index 2c72a7f0c..1040caa4b 100644 --- a/tests/ovs-vswitchd.at +++ b/tests/ovs-vswitchd.at @@ -84,13 +84,8 @@ kill $pid # check the fakelog, should only see one ERR for reporting # the existing ovs-vswitchd process and one WARN for killing # the process. -AT_CHECK([grep ERR fakelog | wc -l], [0], [dnl -1 -]) - -AT_CHECK([grep WARN fakelog | wc -l], [0], [dnl -1 -]) +AT_CHECK([test `grep ERR fakelog | wc -l` -eq 1]) +AT_CHECK([test `grep WARN fakelog | wc -l` -eq 1]) AT_CHECK([grep ERR fakelog | sed -e 's/^.*ERR|//; s/pid [[0-9]]*//'], [0], [dnl another ovs-vswitchd process is running, disabling this process () until it goes away -- 2.20.1