Skip to content

Merge pull request #11 from Ccheers/dev #71

Merge pull request #11 from Ccheers/dev

Merge pull request #11 from Ccheers/dev #71

Workflow file for this run

on: [push, pull_request]
name: Test
jobs:
test:
services:
etcd:
image: gcr.io/etcd-development/etcd:v3.5.0
ports:
- 2379:2379
env:
ETCD_LISTEN_CLIENT_URLS: http://0.0.0.0:2379
ETCD_ADVERTISE_CLIENT_URLS: http://0.0.0.0:2379
strategy:
matrix:
go-version: [1.19.x]
os: [ubuntu-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/setup-go@v3
with:
go-version: ${{ matrix.go-version }}
- uses: actions/checkout@v3
- name: Format
run: if [ "$(gofmt -s -l . | wc -l)" -gt 0 ]; then exit 1; fi
- name: Vet
run: "go vet ./..."
- name: Install Staticcheck
uses: dominikh/[email protected]
with:
version: "2022.1.1"
install-go: false
cache-key: ${{ matrix.go-version }}
- name: Staticcheck
run: "staticcheck ./..."
- name: Test
run: "go test ./..."