Skip to content

Deposit box tests

Deposit box tests #678

Workflow file for this run

name: Tests
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
tests:
runs-on: windows-latest
steps:
- name: Fetch Simba 2 download URL
id: simba-url
run: |
$url = "https://raw.githubusercontent.com/Villavu/Simba-Build-Archive/refs/heads/main/latest.win64"
$response = Invoke-WebRequest -Uri $url -UseBasicParsing
$baseUrl = $response.Content.Trim() -replace 'Win64\.zip\?raw=true$', ''
Write-Output "Base URL: $baseUrl"
"baseUrl=$baseUrl" | Out-File -FilePath $env:GITHUB_OUTPUT -Encoding utf8 -Append
New-Item -Path ".\Includes" -ItemType Directory
New-Item -Path ".\Plugins" -ItemType Directory
- name: Download Simba 2.0 (64-bit)
run: |
$baseUrl = "${{ steps.simba-url.outputs.baseUrl }}"
$downloadUrl = "$baseUrl" + "Win64.zip?raw=true"
Write-Output "Download URL (64-bit): $downloadUrl"
$outputFile = ".\download.zip"
Invoke-WebRequest -Uri $downloadUrl -OutFile $outputFile
Expand-Archive -Path $outputFile -DestinationPath . -Force
Remove-Item -Path $outputFile -Force
- name: Download Simba 2.0 (32-bit)
run: |
$baseUrl = "${{ steps.simba-url.outputs.baseUrl }}"
$downloadUrl = "$baseUrl" + "Win32.zip?raw=true"
Write-Output "Download URL (32-bit): $downloadUrl"
$outputFile = ".\download.zip"
Invoke-WebRequest -Uri $downloadUrl -OutFile $outputFile
Expand-Archive -Path $outputFile -DestinationPath . -Force
Remove-Item -Path $outputFile -Force
- name: Checkout wasp-plugins
uses: actions/[email protected]
with:
repository: WaspScripts/wasp-plugins
path: ./Plugins/wasp-plugins
- name: Checkout WaspLib
uses: actions/[email protected]
with:
path: ./Includes/WaspLib
- name: Run tests
shell: bash
run: |
testFiles=(./Includes/WaspLib/tests/*.simba)
for testFile in "${testFiles[@]}"; do
echo "Running test: $testFile" on 32 bits
./Simba-Win32.exe --extractopenssl --run "$testFile"
echo "Running test: $testFile" on 64 bits
./Simba-Win64.exe --extractopenssl --run "$testFile"
done