From 2816990fcfbdd821de6229fb0eb280e313ffc364 Mon Sep 17 00:00:00 2001 From: Mieszko Grodzicki Date: Sat, 31 Dec 2022 12:05:36 +0100 Subject: [PATCH] Tests - initial version. --- .github/workflows/ci.yml | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100644 .github/workflows/ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..5d4edbe --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,40 @@ +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: + repository: 'mgr0dzicki/cargo-semver-action-ref-slice@patch_change' + persist-credentials: true + - name: Run action + uses: ${{ github.repository }} + run-on-major-change: + name: Test with semver violation + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v3 + with: + repository: 'mgr0dzicki/cargo-semver-action-ref-slice@major_change' + persist-credentials: true + - name: Run action + id: action + uses: ${{ github.repository }} + continue-on-error: true + - name: Check if the action failed + if: steps.action.outcome != 'failure' + run: exit 1 \ No newline at end of file