#!/bin/sh

set -e

case $(dpkg --print-architecture) in
    amd64|i386)
        ;;
    *)
        echo "SKIPPED cvc4 not available on this architecture"
        exit 0
        ;;
    esac

indir=debian/tests/why
why3 config --detect-provers > /dev/null 2>&1
for infile in $indir/*.mlw
do
    why3 prove -P CVC4 $infile | grep -q "Valid"
done
