2021-04-15 23:22:04 +08:00
|
|
|
name: Integration Test
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
|
|
|
|
jobs:
|
2022-01-23 05:17:28 +08:00
|
|
|
build:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- name: Checkout
|
|
|
|
uses: actions/checkout@v2
|
|
|
|
- name: Setup Go
|
|
|
|
uses: actions/setup-go@v2
|
|
|
|
with:
|
2022-03-27 23:27:40 +08:00
|
|
|
go-version: 1.18
|
2022-01-23 05:17:28 +08:00
|
|
|
- name: Build
|
|
|
|
run: |
|
2022-03-05 02:36:48 +08:00
|
|
|
env CGO_ENABLED=1 GOOS=linux GOARCH=amd64 go build main.go
|
2022-01-23 05:17:28 +08:00
|
|
|
cd netclient
|
2022-03-04 05:19:25 +08:00
|
|
|
env CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build main.go
|
|
|
|
env CGO_ENABLED=0 GOOS=freebsd GOARCH=amd64 go build main.go
|
|
|
|
env CGO_ENABLED=0 GOOS=darwin GOARCH=amd64 go build main.go
|
|
|
|
env CGO_ENABLED=0 GOOS=windows GOARCH=amd64 go build main.go
|
2021-04-15 23:22:04 +08:00
|
|
|
tests:
|
2021-09-11 03:48:18 +08:00
|
|
|
env:
|
2021-10-20 03:53:01 +08:00
|
|
|
DATABASE: sqlite
|
2022-03-22 04:10:36 +08:00
|
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
os: [macos-latest, ubuntu-latest, windows-latest]
|
2021-04-15 23:22:04 +08:00
|
|
|
steps:
|
|
|
|
- name: Checkout
|
|
|
|
uses: actions/checkout@v2
|
2022-01-07 04:05:38 +08:00
|
|
|
- name: Setup Go
|
|
|
|
uses: actions/setup-go@v2
|
|
|
|
with:
|
2022-04-22 16:44:15 +08:00
|
|
|
go-version: 1.18
|
2021-04-15 23:22:04 +08:00
|
|
|
- name: run tests
|
|
|
|
run: |
|
2021-05-10 03:55:47 +08:00
|
|
|
go test -p 1 ./... -v
|
2021-09-11 03:48:18 +08:00
|
|
|
env:
|
2021-10-20 03:53:01 +08:00
|
|
|
DATABASE: sqlite
|
|
|
|
CLIENT_MODE: "off"
|
2022-03-22 04:10:36 +08:00
|
|
|
|