# HG changeset patch # User Chris Cannam # Date 1484955579 0 # Node ID 2ada256e47e1c8d7abca9581b47e70555c332fd8 # Parent 0876b5e67afe426586a22098bae3a709c74557da Cut any spurious whitespace from wc output diff -r 0876b5e67afe -r 2ada256e47e1 vamp-server/test.sh --- a/vamp-server/test.sh Fri Jan 20 22:24:44 2017 +0000 +++ b/vamp-server/test.sh Fri Jan 20 23:39:39 2017 +0000 @@ -125,15 +125,15 @@ # probably a bit fragile, let's just count the number of plugins # First, with no "from" arg to the list call - list_no_from=$(head -n +1 "$allrespfile" | fmt -1 | grep '"key"' | wc -l) + list_no_from=$(head -n +1 "$allrespfile" | fmt -1 | grep '"key"' | wc -l | sed 's/[^0-9]//g') # Now with a "from" arg that includes the library that exists list_with_good_from=$(tail -n +2 "$allrespfile" | head -n +1 | fmt -1 | - grep '"key"' | wc -l) + grep '"key"' | wc -l | sed 's/[^0-9]//g') # Now with a "from" arg that doesn't include any real library list_with_bad_from=$(tail -n +3 "$allrespfile" | head -n +1 | fmt -1 | - grep '"key"' | wc -l) + grep '"key"' | wc -l | sed 's/[^0-9]//g') if [ "$list_no_from" != "6" ]; then echo "Wrong number of plugins from list response without \"from\" arg"