Move unit testing into the make script.
This commit is contained in:
committed by
abcdefg30
parent
5bcb1a678c
commit
de22556153
3
.github/workflows/ci.yml
vendored
3
.github/workflows/ci.yml
vendored
@@ -70,8 +70,7 @@ jobs:
|
||||
# Work around runtime failures on the GH Actions runner
|
||||
dotnet nuget add source https://api.nuget.org/v3/index.json -n nuget.org
|
||||
.\make.ps1 check
|
||||
dotnet build OpenRA.Test\OpenRA.Test.csproj -c Debug --nologo -p:TargetPlatform=win-x64
|
||||
dotnet test bin\OpenRA.Test.dll --test-adapter-path:.
|
||||
.\make.ps1 tests
|
||||
|
||||
- name: Check Mods
|
||||
run: |
|
||||
|
||||
8
make.ps1
8
make.ps1
@@ -110,6 +110,13 @@ function Test-Command
|
||||
InvokeCommand "$utilityPath ra --check-yaml"
|
||||
}
|
||||
|
||||
function Tests-Command
|
||||
{
|
||||
Write-Host "Running unit tests..." -ForegroundColor Cyan
|
||||
dotnet build OpenRA.Test\OpenRA.Test.csproj -c Debug --nologo -p:TargetPlatform=win-x64
|
||||
dotnet test bin\OpenRA.Test.dll --test-adapter-path:.
|
||||
}
|
||||
|
||||
function Check-Command
|
||||
{
|
||||
Write-Host "Compiling in Debug configuration..." -ForegroundColor Cyan
|
||||
@@ -253,6 +260,7 @@ switch ($execute)
|
||||
{"version", "v" -contains $_} { Version-Command }
|
||||
{"clean", "c" -contains $_} { Clean-Command }
|
||||
{"test", "t" -contains $_} { Test-Command }
|
||||
{"tests", "ut" -contains $_} { Tests-Command }
|
||||
{"check", "ck" -contains $_} { Check-Command }
|
||||
{"check-scripts", "cs" -contains $_} { Check-Scripts-Command }
|
||||
Default { Write-Host ("Invalid command '{0}'" -f $command) }
|
||||
|
||||
Reference in New Issue
Block a user