Skip to content

Merge pull request #40 from voxpupuli/dependabot/github_actions/actio… #135

Merge pull request #40 from voxpupuli/dependabot/github_actions/actio…

Merge pull request #40 from voxpupuli/dependabot/github_actions/actio… #135

Workflow file for this run

---
name: "ci"
on:
pull_request: {}
push:
branches:
- main
permissions:
contents: read # minimal permissions that we have to grant
jobs:
rubocop_and_matrix:
env:
BUNDLE_WITHOUT: release
runs-on: ubuntu-24.04
outputs:
ruby: ${{ steps.ruby.outputs.versions }}
steps:
- uses: actions/checkout@v6
- name: Install Ruby ${{ matrix.ruby }}
uses: ruby/setup-ruby@v1
with:
ruby-version: "3.4"
bundler-cache: true
- name: Run Rubocop
run: bundle exec rake rubocop
- id: ruby
uses: voxpupuli/ruby-version@v2
test:
name: "Ruby ${{ matrix.ruby }}"
runs-on: ubuntu-24.04
needs: rubocop_and_matrix
strategy:
fail-fast: false
matrix:
ruby: ${{ fromJSON(needs.rubocop_and_matrix.outputs.ruby) }}
env:
BUNDLE_WITHOUT: release:rubocop
steps:
- uses: actions/checkout@v6
- name: Install Ruby ${{ matrix.ruby }}
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
bundler-cache: true
- name: Output Ruby environment
run: bundle env
- name: Build gem
run: gem build --strict --verbose *.gemspec
- name: Run static validation & unit tests
run: bundle exec rake
- name: Run acceptance tests
run: bundle exec rake acceptance
tests:
if: always()
needs:
- rubocop_and_matrix
- test
runs-on: ubuntu-24.04
name: Test suite
steps:
- name: Decide whether the needed jobs succeeded or failed
uses: re-actors/alls-green@release/v1
with:
jobs: ${{ toJSON(needs) }}