Skip to content

Fix test

Fix test #55

Workflow file for this run

name: CI
on: [push]
jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
go-version: ['1.12.x', '1.13.x', '1.14.x']
test-type: ['unit', 'e2e-dep', 'e2e-mod']
fail-fast: false
steps:
- uses: actions/setup-go@v1
with:
go-version: ${{ matrix.go-version }}
env:
GOPATH: /home/runner/go
- uses: actions/checkout@v1
- run: go mod download
- run: |
mkdir -p $GOPATH/bin
curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh
echo "$GOPATH/bin" >> $GITHUB_PATH
if: matrix.test-type == 'e2e-dep'
- run: go test -v -race ./...
if: matrix.test-type == 'unit'
- run: go test -v -run Mod ./...
working-directory: ./tests/e2e
if: matrix.test-type == 'e2e-mod'
- run: go test -v -run Dep ./...
working-directory: ./tests/e2e
if: matrix.test-type == 'e2e-dep'
build:
runs-on: ubuntu-latest
steps:
- uses: actions/setup-go@v1
with:
go-version: 1.14
- uses: actions/checkout@v1
- run: go mod download
- uses: izumin5210/action-go-crossbuild@v1.0.0
with:
package: ./cmd/gex
- uses: softprops/action-gh-release@v1
with:
files: './dist/*'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
if: startsWith(github.ref, 'refs/tags/')
- uses: izumin5210/action-homebrew-tap@v1.0.0
with:
tap: izumin5210/homebrew-tools
token: ${{ secrets.GITHUB_TOKEN }}
tap-token: ${{ secrets.TAP_GITHUB_TOKEN }}
if: startsWith(github.ref, 'refs/tags/')