Test Suite #1970
This file contains hidden or 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: Test Suite | |
| # Run against all commits and pull requests. | |
| on: | |
| workflow_dispatch: | |
| schedule: | |
| - cron: '0 0 * * *' | |
| push: | |
| pull_request: | |
| jobs: | |
| test_matrix: | |
| runs-on: ubuntu-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| ruby: | |
| - '3.2' | |
| - '3.3' | |
| - '3.4' | |
| - '4.0' | |
| rails: | |
| - '71' | |
| - '72' | |
| - '80' | |
| - '81' | |
| env: | |
| BUNDLE_GEMFILE: gemfiles/rails_${{ matrix.rails }}.gemfile | |
| COVERAGE: 'true' | |
| COVERAGE_DIR: coverage/ruby_${{ matrix.ruby }}_rails_${{ matrix.rails }} | |
| steps: | |
| - uses: actions/checkout@v5 | |
| - name: Set up Ruby | |
| uses: ruby/setup-ruby@v1 | |
| with: | |
| ruby-version: ${{ matrix.ruby }} | |
| bundler-cache: true | |
| - name: Run tests | |
| run: bundle exec rake spec | |
| - name: Upload coverage artifact | |
| if: always() | |
| uses: actions/upload-artifact@v7 | |
| with: | |
| name: coverage-ruby-${{ matrix.ruby }}-rails-${{ matrix.rails }} | |
| path: coverage/ | |
| if-no-files-found: ignore | |
| rubocop: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v5 | |
| - name: Set up Ruby | |
| uses: ruby/setup-ruby@v1 | |
| with: | |
| ruby-version: '3.4' | |
| bundler-cache: true | |
| - name: Run RuboCop | |
| run: bundle exec rubocop . | |
| finish: | |
| runs-on: ubuntu-latest | |
| needs: [ test_matrix, rubocop ] | |
| steps: | |
| - name: Wait for status checks | |
| run: echo "All Green!" |