Build #311
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
types: [opened, synchronize, reopened] | |
schedule: | |
- cron: '0 0 * * 1' | |
jobs: | |
lint: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout source | |
uses: actions/checkout@v4 | |
- name: Setup ruby | |
uses: ruby/setup-ruby@v1 | |
with: | |
# Set to `TargetRubyVersion` in `.rubocop.yml` | |
ruby-version: '2.5' | |
- name: Bundle | |
run: bundle install --jobs 4 --retry 3 | |
- name: Lint | |
run: bundle exec rubocop | |
test: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
ruby: | |
- '2.4' | |
- '2.5' | |
- '2.6' | |
- '2.7' | |
- '3.0' | |
- '3.1' | |
- '3.2' | |
- '3.3' | |
gemfile: | |
- rails50.gemfile | |
- rails51.gemfile | |
- rails52.gemfile | |
- rails60.gemfile | |
- rails61.gemfile | |
- rails70.gemfile | |
- rails71.gemfile | |
exclude: | |
- ruby: '2.4' | |
gemfile: rails60.gemfile | |
- ruby: '2.4' | |
gemfile: rails61.gemfile | |
- ruby: '2.4' | |
gemfile: rails70.gemfile | |
- ruby: '2.4' | |
gemfile: rails71.gemfile | |
- ruby: '2.5' | |
gemfile: rails60.gemfile | |
- ruby: '2.5' | |
gemfile: rails61.gemfile | |
- ruby: '2.5' | |
gemfile: rails70.gemfile | |
- ruby: '2.5' | |
gemfile: rails71.gemfile | |
- ruby: '2.6' | |
gemfile: rails70.gemfile | |
- ruby: '2.6' | |
gemfile: rails71.gemfile | |
- ruby: '3.0' | |
gemfile: rails50.gemfile | |
- ruby: '3.0' | |
gemfile: rails51.gemfile | |
- ruby: '3.0' | |
gemfile: rails52.gemfile | |
- ruby: '3.1' | |
gemfile: rails50.gemfile | |
- ruby: '3.1' | |
gemfile: rails51.gemfile | |
- ruby: '3.1' | |
gemfile: rails52.gemfile | |
- ruby: '3.2' | |
gemfile: rails50.gemfile | |
- ruby: '3.2' | |
gemfile: rails51.gemfile | |
- ruby: '3.2' | |
gemfile: rails52.gemfile | |
- ruby: '3.3' | |
gemfile: rails50.gemfile | |
- ruby: '3.3' | |
gemfile: rails51.gemfile | |
- ruby: '3.3' | |
gemfile: rails52.gemfile | |
env: | |
CI: true | |
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }} | |
BUNDLE_GEMFILE: gemfiles/${{ matrix.gemfile }} | |
steps: | |
- name: Checkout source | |
uses: actions/checkout@v4 | |
- name: Setup System | |
run: | | |
sudo apt-get update | |
sudo apt-get install libsqlite3-dev | |
- name: Setup Ruby ${{ matrix.ruby }} | |
uses: ruby/setup-ruby@v1 | |
with: | |
ruby-version: ${{ matrix.ruby }} | |
- name: Bundle | |
run: bundle install --jobs 4 --retry 3 | |
- name: Test | |
run: bundle exec rspec | |
- name: Coveralls Parallel | |
uses: coverallsapp/github-action@v2 | |
with: | |
parallel: true | |
flag-name: run ${{ join(matrix.*, ' - ') }} | |
path-to-lcov: ./coverage/lcov.info | |
finish: | |
needs: test | |
if: ${{ always() }} | |
runs-on: ubuntu-latest | |
steps: | |
- name: Coveralls Finished | |
uses: coverallsapp/github-action@v2 | |
with: | |
parallel-finished: true |