mirror of
https://github.com/bunny-lab-io/Borealis.git
synced 2025-10-26 19:41:57 -06:00
Add Engine API tests for Stage 4
This commit is contained in:
21
Borealis.ps1
21
Borealis.ps1
@@ -9,6 +9,7 @@ param(
|
||||
[switch]$Vite,
|
||||
[switch]$Flask,
|
||||
[switch]$Quick,
|
||||
[switch]$EngineTests,
|
||||
[string]$InstallerCode = ''
|
||||
)
|
||||
|
||||
@@ -17,6 +18,26 @@ $choice = $null
|
||||
$modeChoice = $null
|
||||
$agentSubChoice = $null
|
||||
|
||||
$scriptDir = Split-Path $MyInvocation.MyCommand.Path -Parent
|
||||
|
||||
if ($EngineTests) {
|
||||
Set-Location -Path $scriptDir
|
||||
$env:BOREALIS_PROJECT_ROOT = $scriptDir
|
||||
|
||||
$python = Get-Command python3 -ErrorAction SilentlyContinue
|
||||
if (-not $python) {
|
||||
$python = Get-Command python -ErrorAction SilentlyContinue
|
||||
}
|
||||
|
||||
if (-not $python) {
|
||||
Write-Host "Python interpreter not found. Install Python 3 to run Engine tests." -ForegroundColor Red
|
||||
exit 1
|
||||
}
|
||||
|
||||
& $python.Source -m pytest 'Data/Engine/Unit_Tests'
|
||||
exit $LASTEXITCODE
|
||||
}
|
||||
|
||||
if ($Server -and $Agent) {
|
||||
Write-Host "Cannot use -Server and -Agent together." -ForegroundColor Red
|
||||
exit 1
|
||||
|
||||
Reference in New Issue
Block a user