diff options
Diffstat (limited to 'tests')
| -rwxr-xr-x | tests | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -1,9 +1,11 @@ #!/bin/sh # Test suite for mp. +# Usage: [FAILFAST=1] tests [pattern] +# Example: tests "obj*" run() { [ "$filter" ] && case $1 in ($filter) ;; (*) return; esac - out=$(printf %s "$2" | ./mp 2>&1) + out=$(./mp -v str=1 "$2" 2>&1) [ "$out" = "$3" ] && pass=$((pass + 1)) && return printf "%s FAIL\nWant: '%s'\n Got: '%s'\n" "$1" "$3" "$out" fail=$((fail + 1)) |
