name: CI
on: [pull_request]
jobs:
  tests:
    name: Tests
    runs-on: ubuntu-latest
    strategy:
      matrix:
        ruby-version: [3.1, '3.0', 2.7, 2.6, 2.5]
    steps:
      - uses: actions/checkout@v2
      - name: Set up Ruby ${{ matrix.ruby-version }}
        uses: ruby/setup-ruby@v1
        with:
          ruby-version: ${{ matrix.ruby-version }}
      - name: Install gems
        run: |
          bundle config path vendor/bundle
          bundle install --jobs 4 --retry 3
      - name: Run tests
        run: bundle exec rake
      - name: Run StandardRB
        run: bundle exec standardrb
