summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlex Flint <[email protected]>2021-04-19 21:54:04 -0700
committerGitHub <[email protected]>2021-04-19 21:54:04 -0700
commitcfe0d0ab44efe2937d2922d1b309281ba3afbb4d (patch)
tree39e4c7079f745eb7ecf1453b3b6f0859d9d8b719
parentca571db22112d80c3dad1ec372ec9f3a3c435c7c (diff)
parent041fe266f89284cff1561286958cb88fdd3c0e22 (diff)
Merge pull request #5 from alexflint/continuous-integration
Setup continuous integration with github workflows
-rw-r--r--.github/workflows/go.yml37
1 files changed, 37 insertions, 0 deletions
diff --git a/.github/workflows/go.yml b/.github/workflows/go.yml
new file mode 100644
index 0000000..3dbb91d
--- /dev/null
+++ b/.github/workflows/go.yml
@@ -0,0 +1,37 @@
+name: Go
+
+on:
+ push:
+ branches: [ master ]
+ pull_request:
+ branches: [ master ]
+
+jobs:
+
+ build_and_test:
+ name: Build and test
+ runs-on: ubuntu-latest
+
+ strategy:
+ fail-fast: false
+ matrix:
+ go: ['1.13', '1.14', '1.15', '1.16']
+
+ steps:
+ - id: go
+ name: Set up Go
+ uses: actions/setup-go@v1
+ with:
+ go-version: ${{ matrix.go }}
+
+ - name: Checkout
+ uses: actions/checkout@v2
+
+ - name: Build
+ run: go build -v .
+
+ - name: Test
+ run: go test -v -coverprofile=profile.cov .
+
+ - name: Send coverage
+ run: bash <(curl -s https://codecov.io/bash) -f profile.cov