-
-
Notifications
You must be signed in to change notification settings - Fork 0
55 lines (50 loc) · 2.21 KB
/
test_and_release.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
---
name: Test And Release
on:
push:
tags:
- "v*"
jobs:
Unit_Tests:
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- name: Cache tools
uses: actions/cache@v4
id: cache
with:
path: |
autoit-v3-setup.exe
SciTE4AutoIt3.exe
C:\Program Files (x86)\AutoIt3\SciTE\Au3Stripper
key: v4
- name: Download tools
if: steps.cache.outputs.cache-hit != 'true'
run: |
curl -sSfL https://www.autoitscript.com/cgi-bin/getfile.pl?autoit3/autoit-v3-setup.exe -o autoit-v3-setup.exe `
-sSfL https://www.autoitscript.com/cgi-bin/getfile.pl?../autoit3/scite/download/SciTE4AutoIt3.exe -o SciTE4AutoIt3.exe `
-sSfLO https://www.autoitscript.com/autoit3/scite/download/Au3Stripper.zip
Expand-Archive Au3Stripper.zip "${env:ProgramFiles(x86)}\AutoIt3\SciTE\Au3Stripper"
- name: Install tools
run: |
Start-Process autoit-v3-setup.exe -ArgumentList /S -NoNewWindow -Wait
Start-Process SciTE4AutoIt3.exe -ArgumentList /S -NoNewWindow -Wait
- name: Run Unit Tests
run: |
$process86 = Start-Process "${env:ProgramFiles(x86)}\AutoIt3\AutoIt3.exe" "`"${env:ProgramFiles(x86)}\AutoIt3\SciTE\AutoIt3Wrapper\AutoIt3Wrapper.au3`" /run /prod /x86 /ErrorStdOut /in Tests/Test.au3 /UserParams" -PassThru -NoNewWindow
Wait-Process -InputObject $process86
$process64 = Start-Process "${env:ProgramFiles(x86)}\AutoIt3\AutoIt3.exe" "`"${env:ProgramFiles(x86)}\AutoIt3\SciTE\AutoIt3Wrapper\AutoIt3Wrapper.au3`" /run /prod /x86 /ErrorStdOut /in Tests/Test.au3 /UserParams" -PassThru -NoNewWindow
Wait-Process -InputObject $process64
if ($process86.ExitCode -ne 0) {
Write-Error "[x86] $($process86.ExitCode) Vector Unit Tests failed"
}
if ($process64.ExitCode -ne 0) {
Write-Error "[x64] $($process64.ExitCode) Vector Unit Tests failed"
}
- uses: "marvinpinto/action-automatic-releases@latest"
with:
repo_token: "${{ secrets.GITHUB_TOKEN }}"
prerelease: false
files: |
README.md
*.au3