-
Notifications
You must be signed in to change notification settings - Fork 161
47 lines (42 loc) · 1.28 KB
/
beta.yaml
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
# Run tests using the beta Rust compiler
name: Beta Rust
on:
schedule:
# 06:50 UTC every Monday
- cron: '50 6 * * 1'
workflow_dispatch:
# TODO: temporary to test in PR only
pull_request:
concurrency:
group: beta-${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
tests:
uses: './.github/workflows/tests.yaml'
with:
rust-version: beta
notify:
needs: tests
if: ${{ always() }}
runs-on: ubuntu-latest
steps:
- name: Extract test results
if: ${{ always() }}
run: |
printf '${{ toJSON(needs) }}\n'
result=$(echo '${{ toJSON(needs) }}' | jq .tests.result | tr -d \")
echo TESTS_RESULT=$result
echo TESTS_RESULT=$result >>$GITHUB_ENV
- run: |
echo $TEST_RESULTS
echo ${{ env.TEST_RESULTS == 'failure' }}
echo ${{ env.TEST_RESULTS != 'failure' }}
if: ${{ always() }}
- uses: n0-computer/discord-webhook-notify@v1
if: ${{ always() && env.TEST_RESULTS == 'failure' }}
with:
severity: error
details: |
rustc beta tests failed
see https://github.com/n0-computer/iroh/actions/workflows/beta.yaml
webhookUrl: ${{ secrets.DISCORD_N0_GITHUB_CHANNEL_WEBHOOK_URL }}