blob: ab1a6c425aaab0cb09598cabe950ef9ddf2f11e3 [file] [log] [blame]
Jan Tattermuschb1a921c2015-05-12 19:27:53 -07001#!/bin/bash
Jan Tattermuschb1a921c2015-05-12 19:27:53 -07002
Jan Tattermuschb1a921c2015-05-12 19:27:53 -07003CONFIG=Release
Jan Tattermuschb1a921c2015-05-12 19:27:53 -07004SRC=$(dirname $0)/src
5
6set -ex
7
Jon Skeet10a8fb42016-07-14 22:01:47 +01008echo Building relevant projects.
Jon Skeetf26e8c22017-05-04 08:51:46 +01009dotnet restore $SRC/Google.Protobuf.sln
10dotnet build -c $CONFIG $SRC/Google.Protobuf.sln
Jan Tattermuschb1a921c2015-05-12 19:27:53 -070011
12echo Running tests.
James Newton-Kingaa159312021-11-10 08:49:53 +130013# Only test netcoreapp3.1, which uses the .NET Core runtime.
Jon Skeet10a8fb42016-07-14 22:01:47 +010014# If we want to test the .NET 4.5 version separately, we could
15# run Mono explicitly. However, we don't have any differences between
Jan Tattermusch753daae2019-03-12 04:40:46 -040016# the .NET 4.5 and netstandard2.1 assemblies.
James Newton-Kingaa159312021-11-10 08:49:53 +130017dotnet test -c $CONFIG -f netcoreapp3.1 $SRC/Google.Protobuf.Test/Google.Protobuf.Test.csproj