-
Notifications
You must be signed in to change notification settings - Fork 1
59 lines (56 loc) · 1.65 KB
/
integration-test.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
54
55
56
57
58
59
name: integration-test
on:
push:
branches:
- main
issue_comment:
types: [created, edited]
jobs:
integration-on-push:
permissions:
contents: read
if: github.event_name == 'push'
strategy:
matrix:
go: [stable]
os: [ubuntu-latest]
name: test
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: ${{ matrix.go }}
- name: Run integration test
env:
GROQ_API_KEY: ${{ secrets.GROQ_API_KEY }}
run: make integration-test
integration-on-comment:
permissions:
contents: read
pull-requests: write
if: contains('Kcrong,resoliwan,SeongIkKim', github.triggering_actor) && contains(github.event.comment.body, '/run integration')
strategy:
matrix:
go: [ stable ]
os: [ ubuntu-latest ]
name: test
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: ${{ matrix.go }}
- name: Run integration test
env:
GROQ_API_KEY: ${{ secrets.GROQ_API_KEY }}
run: make integration-test
- uses: actions/github-script@v7
with:
script: |
github.rest.issues.createComment({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
body: '👋 Thanks for reporting! I have started the integration test. You can check the status [here](${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }})'
})