cargo-semver-checks/.github/workflows/ci.yml

59 lines
1.6 KiB
YAML
Raw Permalink Normal View History

2022-12-31 12:05:36 +01:00
name: CI
on:
pull_request:
push:
branches:
- main
2023-02-27 21:47:09 +01:00
env:
RUST_BACKTRACE: 1
2022-12-31 12:05:36 +01:00
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
2023-02-23 18:34:06 +01:00
test-build:
2023-02-22 11:42:39 +01:00
name: Test build
uses: ./.github/workflows/test-build.yml
2023-02-21 12:18:52 +01:00
2022-12-31 13:03:06 +01:00
test-action:
2023-02-25 14:16:59 +01:00
name: Smoke test the action
2023-01-09 00:46:08 +01:00
uses: ./.github/workflows/test-action.yml
2023-02-25 14:16:59 +01:00
test-inputs:
name: Test action inputs
uses: ./.github/workflows/test-inputs.yml
test-cache:
name: Test rustdoc caching
uses: ./.github/workflows/test-cache.yml