80 lines
2.3 KiB
YAML
80 lines
2.3 KiB
YAML
on: [push, pull_request]
|
|
name: Test
|
|
jobs:
|
|
Windows_x64:
|
|
runs-on: windows-latest
|
|
steps:
|
|
- name: Install Go
|
|
uses: actions/setup-go@v1
|
|
with:
|
|
go-version: 1.13.x
|
|
- name: Checkout code
|
|
uses: actions/checkout@v1
|
|
- name: Install Deps
|
|
shell: pwsh
|
|
run: |
|
|
Invoke-WebRequest -OutFile ultralight.7z https://ultralight-sdk.sfo2.cdn.digitaloceanspaces.com/ultralight-sdk-latest-win-x64.7z
|
|
7z e ultralight.7z *.dll -r
|
|
- name: Test
|
|
run: go test
|
|
Windows_x32:
|
|
runs-on: windows-latest
|
|
steps:
|
|
- name: Install Go
|
|
uses: actions/setup-go@v1
|
|
with:
|
|
go-version: 1.13.x
|
|
- name: Checkout code
|
|
uses: actions/checkout@v1
|
|
- name: Install Deps
|
|
shell: pwsh
|
|
run: |
|
|
Invoke-WebRequest -OutFile gcc.zip http://sourceforge.net/projects/tdm-gcc/files/TDM-GCC%205%20series/5.1.0-tdm-1%20SJLJ/gcc-5.1.0-tdm-1-core.zip/download
|
|
Expand-Archive -Path gcc.zip -DestinationPath C:/tdmgcc
|
|
Invoke-WebRequest -OutFile ultralight.7z https://ultralight-sdk.sfo2.cdn.digitaloceanspaces.com/ultralight-sdk-latest-win-x86.7z
|
|
7z e ultralight.7z *.dll -r
|
|
- name: Test
|
|
env:
|
|
GOARCH: 386
|
|
CGO_ENABLED: 1
|
|
CC: C:/tdmgcc/bin/gcc.exe
|
|
run: |
|
|
go env
|
|
go test
|
|
Linux_x64:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Install Go
|
|
uses: actions/setup-go@v1
|
|
with:
|
|
go-version: 1.13.x
|
|
- name: Checkout code
|
|
uses: actions/checkout@v1
|
|
- name: Install Deps
|
|
run: |
|
|
wget -O ultralight.7z https://ultralight-sdk.sfo2.cdn.digitaloceanspaces.com/ultralight-sdk-latest-linux-x64.7z
|
|
7z e ultralight.7z *.so -r
|
|
sudo apt update && sudo apt install -y xorg openbox
|
|
sudo nohup Xorg :0 &
|
|
- name: Test
|
|
env:
|
|
LD_LIBRARY_PATH: .
|
|
DISPLAY: :0
|
|
run: go test -ldflags "-r ."
|
|
Mac_x64:
|
|
runs-on: macOS-latest
|
|
steps:
|
|
- name: Install Go
|
|
uses: actions/setup-go@v1
|
|
with:
|
|
go-version: 1.13.x
|
|
- name: Checkout code
|
|
uses: actions/checkout@v1
|
|
- name: Install Deps
|
|
run: |
|
|
brew install p7zip
|
|
wget -O ultralight.7z https://ultralight-sdk.sfo2.cdn.digitaloceanspaces.com/ultralight-sdk-latest-mac-x64.7z
|
|
7z e ultralight.7z *.dylib -r
|
|
- name: Test
|
|
run: go test -ldflags "-r ."
|