-
Notifications
You must be signed in to change notification settings - Fork 25
53 lines (41 loc) · 1.13 KB
/
pull-request.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
name: Build and Run Tests
on: [pull_request]
jobs:
build:
name: Code generation & compile
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-2019, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v1
- name: Generate protos and build project (Powershell)
if: ${{ matrix.os == 'windows-2019' }}
run: .\build.ps1 -generateProtos
shell: pwsh
- name: Generate protos and build project (Bash)
if: ${{ matrix.os != 'windows-2019' }}
run: ./build.sh --generate-protos
- name: Misc tests
run: go test -v ./esdb -run TestMisc
tests:
needs: build
name: Tests
strategy:
fail-fast: false
matrix:
version: [previous-lts, lts, latest]
uses: ./.github/workflows/tests.yml
with:
esdb_version: ${{ matrix.version }}
linting:
needs: tests
name: Linting
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- name: Linting
run: go vet ./...
- name: Code formatting checks
run: diff -u <(echo -n) <(goimports -d ./)