build.sh improvements

- run `go test ./...` and STOP on error
- run `go build` and STOP on error
- run `go install` and STOP on error
This commit is contained in:
Travis McLane
2020-03-28 10:34:27 -05:00
committed by Lea Anthony
parent 404cd7d14e
commit 773bad45f6
2 changed files with 23 additions and 9 deletions

View File

@@ -15,9 +15,30 @@ cd lib/renderer
mewn
cd ../..
echo "**** Installing Wails locally ****"
echo "**** Checking if Wails passes unit tests ****"
if ! go test ./...
then
echo ""
echo "ERROR: Unit tests failed!"
exit 1;
fi
cd cmd/wails
go install
echo "**** Checking if Wails compiles ****"
if ! go build .
then
echo ""
echo "ERROR: Build failed!"
exit 1;
fi
echo "**** Installing Wails locally ****"
if ! go install
then
echo ""
echo "ERROR: Install failed!"
exit 1;
fi
cd ../..
echo "**** Tidying the mods! ****"