Skip to content

Commit

Permalink
Add github actions
Browse files Browse the repository at this point in the history
  • Loading branch information
belak committed Mar 17, 2020
1 parent cb6bd1c commit 3847373
Show file tree
Hide file tree
Showing 2 changed files with 47 additions and 24 deletions.
47 changes: 47 additions & 0 deletions .github/workflows/ci.yml
@@ -0,0 +1,47 @@
name: Go

on: [push, pull_request]

env:
GO11MODULE: on

jobs:
build:
name: Build
runs-on: ubuntu-latest

steps:
- name: Set up Go
uses: actions/setup-go@v2-beta
with:
go-version: '^1.7'

- name: Check out code
uses: actions/checkout@9a3a9ade
with:
submodules: true

- name: Clean up extra files
run: rm ./testcases/*.go

- name: Run golangci-lint
uses: actions-contrib/golangci-lint@v1
env:
GOROOT: ''
with:
golangci_lint_version: 'v1.23.6'

- name: Download deps
run: go mod download

- name: Run tests
run: go test -race -v ./...

- name: Submit coverage report
env:
COVERALLS_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
go test -covermode=count -coverprofile=profile.cov
GO111MODULE=off go get github.com/mattn/goveralls
$(go env GOPATH)/bin/goveralls -coverprofile=profile.cov -service=github
24 changes: 0 additions & 24 deletions .travis.yml

This file was deleted.

0 comments on commit 3847373

Please sign in to comment.