#!/bin/sh
printf "Testing errors..."
./asy -q -sysdir base -noautoplain -debug errortest 2> errors.temp
result=`diff errors.temp errors`
if test "$result" = ""; then
echo PASSED.
else
echo FAILED.
echo "$result"
exit 1
fi
printf "Testing deconstruct..."
./asy -dvisvgmOptions=-v0 -q -sysdir base -outpipe 2 -xasy -c "draw(unitsquare); deconstruct()" 2> deconstruct.temp
result=`diff deconstruct.temp deconstruct`
rm -f _1.svg deconstruct.temp
if test "$result" = ""; then
echo PASSED.
else
echo FAILED.
echo "$result"
exit 1
fi
