-
Notifications
You must be signed in to change notification settings - Fork 54
41 lines (32 loc) · 910 Bytes
/
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
name: test
on:
workflow_dispatch:
push:
pull_request:
jobs:
testbed:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Install Rust toolchain
run: |
rustup default nightly
rustup update
- name: Build project
run: cargo build
- name: Run testbed
run: cargo run --bin testbed -- --api-token $API_TOKEN
env:
API_TOKEN: ${{ secrets.API_TOKEN }}
- name: Read results.md
if: github.event_name == 'pull_request'
run: |
echo 'RESULTS_MD<<EOF' >> $GITHUB_ENV
cat results.md >> $GITHUB_ENV
echo 'EOF' >> $GITHUB_ENV
- name: Comment Testbed result
uses: peter-evans/create-or-update-comment@v3
if: github.event_name == 'pull_request'
with:
body: ${{ env.RESULTS_MD }}