2022-12-31 12:05:36 +01:00
|
|
|
name: CI
|
|
|
|
|
|
|
|
on:
|
|
|
|
pull_request:
|
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- main
|
|
|
|
|
|
|
|
env:
|
|
|
|
RUST_BACKTRACE: 1
|
|
|
|
CARGO_TERM_COLOR: always
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
run-on-patch-change:
|
|
|
|
name: Test without semver violation
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- name: Checkout
|
|
|
|
uses: actions/checkout@v3
|
|
|
|
with:
|
2022-12-31 12:15:30 +01:00
|
|
|
repository: mgr0dzicki/cargo-semver-action-ref-slice@patch_change
|
2022-12-31 12:05:36 +01:00
|
|
|
persist-credentials: true
|
|
|
|
- name: Run action
|
2022-12-31 12:11:21 +01:00
|
|
|
uses: ./
|
2022-12-31 12:05:36 +01:00
|
|
|
run-on-major-change:
|
|
|
|
name: Test with semver violation
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- name: Checkout
|
|
|
|
uses: actions/checkout@v3
|
|
|
|
with:
|
2022-12-31 12:15:30 +01:00
|
|
|
repository: mgr0dzicki/cargo-semver-action-ref-slice@major_change
|
2022-12-31 12:05:36 +01:00
|
|
|
persist-credentials: true
|
|
|
|
- name: Run action
|
|
|
|
id: action
|
2022-12-31 12:11:21 +01:00
|
|
|
uses: ./
|
2022-12-31 12:05:36 +01:00
|
|
|
continue-on-error: true
|
|
|
|
- name: Check if the action failed
|
|
|
|
if: steps.action.outcome != 'failure'
|
2022-12-31 12:11:21 +01:00
|
|
|
run: exit 1
|