Skip to content

Commit 4c99d0e

Browse files
committed
test(github): add comment_key e2e test workflow
1 parent 3def857 commit 4c99d0e

1 file changed

Lines changed: 51 additions & 0 deletions

File tree

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
name: test-comment-key
2+
3+
on:
4+
pull_request:
5+
branches:
6+
- dev
7+
types: [opened, synchronize]
8+
9+
jobs:
10+
# Verify sticky behaviour: running twice should update the same comment.
11+
with-comment-key:
12+
name: With comment_key
13+
runs-on: ubuntu-latest
14+
permissions:
15+
issues: write
16+
pull-requests: write
17+
contents: read
18+
steps:
19+
- uses: actions/checkout@v4
20+
21+
- name: Run opencode (sticky)
22+
uses: ./github
23+
with:
24+
model: opencode/minimax-m2.5-free
25+
use_github_token: true
26+
comment_key: test-sticky
27+
prompt: |
28+
Reply with exactly one sentence:
29+
"Sticky comment test — run #${{ github.run_number }}, attempt #${{ github.run_attempt }}."
30+
Do not add anything else.
31+
32+
# Baseline: should create a new comment on every push.
33+
without-comment-key:
34+
name: Without comment_key (baseline)
35+
runs-on: ubuntu-latest
36+
permissions:
37+
issues: write
38+
pull-requests: write
39+
contents: read
40+
steps:
41+
- uses: actions/checkout@v4
42+
43+
- name: Run opencode (non-sticky)
44+
uses: ./github
45+
with:
46+
model: opencode/minimax-m2.5-free
47+
use_github_token: true
48+
prompt: |
49+
Reply with exactly one sentence:
50+
"Non-sticky comment test — run #${{ github.run_number }}, attempt #${{ github.run_attempt }}."
51+
Do not add anything else.

0 commit comments

Comments
 (0)