-
Notifications
You must be signed in to change notification settings - Fork 10
54 lines (51 loc) · 1.3 KB
/
pull_request.yaml
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
54
name: pull_request
on:
pull_request:
jobs:
gen:
name: Code Gen
runs-on: ubuntu-22.04
steps:
- name: Cancel Previous Runs
uses: styfle/cancel-workflow-action@0.11.0
with:
access_token: ${{ github.token }}
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Set up Go
uses: actions/setup-go@v4
with:
go-version-file: go.mod
id: go
- name: Install Protoc
uses: arduino/setup-protoc@v1
with:
version: '3.6.1'
repo-token: ${{ secrets.GITHUB_TOKEN }}
- name: Generate Code
run: |
./ci/check-code-gen.sh
test:
name: Tests
runs-on: ubuntu-22.04
steps:
- name: Cancel Previous Runs
uses: styfle/cancel-workflow-action@0.11.0
with:
access_token: ${{ github.token }}
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Setup Private Repo Permissions
env:
TOKEN: ${{ secrets.PERSONAL_ACCESS_TOKEN }}
run: |
git config --global url."https://${TOKEN}@github.com/solo-io/".insteadOf "https://github.com/solo-io/"
- name: Set up Go
uses: actions/setup-go@v4
with:
go-version-file: go.mod
- name: Run tests
run: |
go test ./test/...