Mother2GbaTranslation/docker-scripts/docker-test-rom-script

27 lines
845 B
PowerShell
Executable File

#!/bin/pwsh
"Starting Dummy services"
$Env:SDL_VIDEODRIVER = "dummy"
pulseaudio -D --exit-idle-time=-1
pactl load-module module-null-sink sink_name=SpeakerOutput sink_properties=device.description="Dummy_Output"
$Env:PATH += ":/home/m2gba/.dotnet:/home/m2gba/.dotnet/tools"
Copy-Item -Path "\home\m2gba\src\*" -Destination "\opt\src" -Recurse -Force
"Starting to build tools"
./build-tools.ps1
if ($LASTEXITCODE -ne 0) { exit -1 }
"Starting to build test rom"
./test.ps1
$LAST_VAL = $LASTEXITCODE
"Copying test log to output"
New-Item -Path "\home\m2gba\src" -Name "out" -ItemType "directory" -Force
Copy-Item -Path ".\bin\test.log" "\home\m2gba\src\out"
Copy-Item -Path ".\bin\m12test.gba" "\home\m2gba\src\out"
if ($LAST_VAL -ne 0) { exit -1 }
"Test ran successfully, please review the ./out folder for the resulting logs and test rom"