-
Notifications
You must be signed in to change notification settings - Fork 3
37 lines (34 loc) · 918 Bytes
/
ut.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
name: Test
on:
pull_request:
paths:
- '.github/workflows/**'
- '**.go'
- 'Makefile'
- 'go.**'
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
test:
name: Test
runs-on: ubuntu-latest
defaults:
run:
working-directory: ./src/github.com/${{ github.repository }}
steps:
- name: Checkout code
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1
with:
path: ./src/github.com/${{ github.repository }}
- name: Install Go
uses: actions/setup-go@v4
with:
go-version: 1.19
- name: Cache Go modules
uses: actions/cache@704facf57e6136b1bc63b828d79edcd491f0ee84 # v3.3.2
with:
path: ~/go/pkg/mod
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
- name: Test
run: make test