-
-
Notifications
You must be signed in to change notification settings - Fork 16
58 lines (50 loc) · 1.58 KB
/
ci.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
name: CI
on:
pull_request:
push:
branches:
- main
env:
RUST_BACKTRACE: 1
jobs:
ci-everything:
name: All CI stages
runs-on: ubuntu-latest
needs:
- test-build
- test-action
- test-inputs
- test-cache
if: ${{ success() || failure() }} # Run this job even if a dependency has failed.
steps:
- name: Job outcomes
run: |
echo "test-build: ${{ needs.test-build.result }}"
echo "test-action: ${{ needs.test-action.result }}"
echo "test-inputs: ${{ needs.test-inputs.result }}"
echo "test-cache: ${{ needs.test-cache.result }}"
# Fail this required job if any of its dependent jobs have failed.
#
# Do not attempt to consolidate these steps into one step, it won't work.
# Multi-line `if` clauses are not evaluated properly: see the intermediate commits in
# https://github.com/obi1kenobi/cargo-semver-checks/pull/405
- if: ${{ needs.test-build.result != 'success' }}
run: exit 1
- if: ${{ needs.test-action.result != 'success' }}
run: exit 1
- if: ${{ needs.test-inputs.result != 'success' }}
run: exit 1
- if: ${{ needs.test-cache.result != 'success' }}
run: exit 1
test-build:
name: Test build
uses: ./.github/workflows/test-build.yml
test-action:
name: Smoke test the action
uses: ./.github/workflows/test-action.yml
test-inputs:
name: Test action inputs
uses: ./.github/workflows/test-inputs.yml
test-cache:
name: Test rustdoc caching
uses: ./.github/workflows/test-cache.yml