From 6e0601d49bf3f5c72959dec3643a2315e298ae3f Mon Sep 17 00:00:00 2001 From: kbth Date: Wed, 30 Apr 2025 21:49:58 +0900 Subject: [PATCH 1/2] CI: serialize DB-dependent tests --- build.ps1 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/build.ps1 b/build.ps1 index f406c745f..59193ff75 100644 --- a/build.ps1 +++ b/build.ps1 @@ -22,8 +22,8 @@ dotnet build ".\Build.csproj" -c Release /p:CI=true Write-Host "Done building." -ForegroundColor "Green" if ($RunTests) { - Write-Host "Running tests: Build.csproj traversal (all frameworks)" -ForegroundColor "Magenta" - dotnet test ".\Build.csproj" -c Release --no-build + Write-Host "Running tests: Build.csproj" -ForegroundColor "Magenta" + dotnet test ".\Build.csproj" -c Release --no-build -p:TestTfmsInParallel=false if ($LastExitCode -ne 0) { Write-Host "Error with tests, aborting build." -Foreground "Red" Exit 1 From f83584b73e692d398c9f7fd676a09004fe029269 Mon Sep 17 00:00:00 2001 From: kbth Date: Wed, 30 Apr 2025 22:37:06 +0900 Subject: [PATCH 2/2] github workflows test --- .github/workflows/main.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 497e5a0bf..7a910196d 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -47,7 +47,7 @@ jobs: - name: .NET Build run: dotnet build Build.csproj -c Release /p:CI=true - name: Dapper Tests - run: dotnet test tests/Dapper.Tests/Dapper.Tests.csproj -c Release --logger GitHubActions /p:CI=true + run: dotnet test tests/Dapper.Tests/Dapper.Tests.csproj -c Release --logger GitHubActions -p:CI=true -p:TestTfmsInParallel=false env: MySqlConnectionString: Server=localhost;Port=${{ job.services.mysql.ports[3306] }};Uid=root;Pwd=root;Database=test;Allow User Variables=true OLEDBConnectionString: Provider=SQLOLEDB;Server=tcp:localhost,${{ job.services.sqlserver.ports[1433] }};Database=tempdb;User Id=sa;Password=Password.;