Skip to content

Commit a1b1a43

Browse files
authored
Create test.yml
1 parent b2cfb1a commit a1b1a43

File tree

1 file changed

+40
-0
lines changed

1 file changed

+40
-0
lines changed

test.yml

+40
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
on: [push, pull_request]
2+
name: Test
3+
jobs:
4+
test:
5+
strategy:
6+
matrix:
7+
go-version: [1.15.x, 1.16.x]
8+
postgres-version: [9.4, 9.5, 9.6, 10, 11, 12]
9+
binary-parameter: [false, true]
10+
os: [ubuntu-latest]
11+
runs-on: ${{ matrix.os }}
12+
steps:
13+
- name: Install Go
14+
uses: actions/setup-go@v2
15+
with:
16+
go-version: ${{ matrix.go-version }}
17+
- uses: harmon758/postgresql-action@v1
18+
with:
19+
postgresql version: ${{ matrix.postgresql-version }}
20+
postgresql db: 'pqgotest'
21+
- name: Create users
22+
run: |
23+
createuser -DRS pqgossltest
24+
createuser -DRS pqgosslcert
25+
- name: Checkout code
26+
uses: actions/checkout@v2
27+
- name: Test
28+
run: PQTEST_BINARY_PARAMETERS=${{ matrix.binary-parameter }} go test ./...
29+
golangci:
30+
strategy:
31+
matrix:
32+
go-version: [1.15.x, 1.16.x]
33+
name: lint
34+
runs-on: ubuntu-latest
35+
steps:
36+
- uses: actions/checkout@v2
37+
- name: golangci-lint
38+
uses: golangci/golangci-lint-action@v2
39+
with:
40+
version: v1.29

0 commit comments

Comments
 (0)