gorm/tests/tests_all.sh

18 lines
406 B
Bash
Raw Normal View History

2020-02-23 07:39:26 +03:00
dialects=("sqlite" "mysql" "postgres" "mssql")
2020-02-23 04:38:48 +03:00
if [[ $(pwd) == *"gorm/tests"* ]]; then
cd ..
fi
for dialect in "${dialects[@]}" ; do
if [ "$GORM_DIALECT" = "" ] || [ "$GORM_DIALECT" = "${dialect}" ]
then
if [ "$GORM_VERBOSE" = "" ]
then
DEBUG=false GORM_DIALECT=${dialect} go test -race ./...
else
DEBUG=false GORM_DIALECT=${dialect} go test -race -v ./...
fi
fi
done