34 lines
873 B
Bash
34 lines
873 B
Bash
|
#!/bin/bash
|
||
|
|
||
|
dotnet clean BitBadger.Documents.sln
|
||
|
dotnet restore BitBadger.Documents.sln
|
||
|
dotnet build BitBadger.Documents.sln --no-restore
|
||
|
|
||
|
cd ./Tests || exit
|
||
|
|
||
|
export BBDOX_PG_PORT=8301
|
||
|
PG_VERSIONS=('12' '13' '14' '15' 'latest')
|
||
|
NET_VERSIONS=('6.0' '7.0' '8.0')
|
||
|
|
||
|
for PG_VERSION in "${PG_VERSIONS[@]}"
|
||
|
do
|
||
|
echo Starting PostgreSQL:$PG_VERSION
|
||
|
docker run -d -p $BBDOX_PG_PORT:5432 --name pg_test -e POSTGRES_PASSWORD=postgres postgres:$PG_VERSION
|
||
|
sleep 4
|
||
|
for NET_VERSION in "${NET_VERSIONS[@]}"
|
||
|
do
|
||
|
if [ "$PG_VERSION" = "latest" ]; then
|
||
|
echo Testing SQLite and PostgreSQL under .NET $NET_VERSION...
|
||
|
dotnet run -f net$NET_VERSION
|
||
|
else
|
||
|
echo Testing PostgreSQL v$PG_VERSION under .NET $NET_VERSION...
|
||
|
BBDOX_PG_ONLY="true" dotnet run -f net$NET_VERSION
|
||
|
fi
|
||
|
done
|
||
|
docker stop pg_test
|
||
|
sleep 2
|
||
|
docker rm pg_test
|
||
|
done
|
||
|
|
||
|
cd .. || exit
|