-
Notifications
You must be signed in to change notification settings - Fork 2
44 lines (39 loc) · 1020 Bytes
/
pr.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
name: pr
on:
pull_request:
branches:
- main
env:
GO_VERSION: 1.23
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/setup-go@v2
with:
go-version: ${{ env.GO_VERSION }}
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: test
run: |
echo '```' > results.comment
echo "$ make test" >> results.comment
make test 2>&1 | tee test.out
cat test.out | tail -20 >> results.comment
echo "-----" >> results.comment
- name: test-race
run: |
make test-race
- name: bench
run: |
echo "$ make bench" >> results.comment
make bench 2>&1 | tee bench.out
cat bench.out >> results.comment
echo '```' >> results.comment
- name: results
if: always()
uses: thollander/actions-comment-pull-request@v2
with:
comment_tag: results
filePath: results.comment