ci: add regression test for step output interpolation (#68) (#73)

Reproduce the exact scenario from issue #68: write a value to
$GITHUB_OUTPUT in a step with an id, assert the runner interpolates
it, then send it through the message input with format: markdown.

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
Bo-Yi Wu
2026-08-16 11:27:58 +08:00
committed by GitHub
co-authored by Claude Fable 5
parent 978281de94
commit a2d0caf64a
+22
View File
@@ -84,6 +84,28 @@ jobs:
token: ${{ secrets.TELEGRAM_TOKEN }}
message_file: tests/message.txt
# Regression test for issue #68: step outputs written to $GITHUB_OUTPUT
# must be usable inside the message input. The step producing the
# output needs an `id` so it can be referenced via steps.<id>.outputs.
- name: set step output
id: repo-discussion
run: |
COUNT=42
echo "discussionCount=$COUNT" >> "$GITHUB_OUTPUT"
- name: verify step output is interpolated
run: |
test "${{ steps.repo-discussion.outputs.discussionCount }}" = "42"
- name: send message with step output (issue #68)
uses: ./
with:
to: ${{ secrets.TELEGRAM_TO }}
token: ${{ secrets.TELEGRAM_TOKEN }}
message: |
There are currently ${{ steps.repo-discussion.outputs.discussionCount }} discussions, come on!
format: markdown
# - name: send message using socks5 proxy URL
# uses: appleboy/telegram-action@master
# with: