diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 5462900..a97f583 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,56 +1,25 @@ -name: Build (Linter + Specs) +name: Test (Linter + Typecheck + Specs) on: [push, pull_request] jobs: - ruby33: + test: runs-on: ubuntu-latest strategy: fail-fast: false + matrix: + - ruby_version: '3.1' + env: gemfiles/ruby31.gemfile + - ruby_version: '3.2' + env: gemfiles/ruby32.gemfile + - ruby_version: '3.3' + env: gemfiles/ruby33.gemfile env: - BUNDLE_GEMFILE: gemfiles/ruby33.gemfile + BUNDLE_GEMFILE: ${{ matrix.env }} steps: - uses: actions/checkout@v4 - uses: supercharge/redis-github-action@1.7.0 - uses: ruby/setup-ruby@v1 with: - ruby-version: '3.3' - bundler-cache: true - - name: (Linter) Rubocop - run: bundle exec rake rubocop - - name: (TypeCheck) Steep - run: bundle exec steep check --jobs 10 - - name: (Test) RSpec - run: bundle exec rake rspec - ruby32: - runs-on: ubuntu-latest - strategy: - fail-fast: false - env: - BUNDLE_GEMFILE: gemfiles/ruby32.gemfile - steps: - - uses: actions/checkout@v4 - - uses: supercharge/redis-github-action@1.7.0 - - uses: ruby/setup-ruby@v1 - with: - ruby-version: '3.2' - bundler-cache: true - - name: (Linter) Rubocop - run: bundle exec rake rubocop - - name: (TypeCheck) Steep - run: bundle exec steep check --jobs 10 - - name: (Test) RSpec - run: bundle exec rake rspec - ruby31: - runs-on: ubuntu-latest - strategy: - fail-fast: false - env: - BUNDLE_GEMFILE: gemfiles/ruby31.gemfile - steps: - - uses: actions/checkout@v4 - - uses: supercharge/redis-github-action@1.7.0 - - uses: ruby/setup-ruby@v1 - with: - ruby-version: '3.1' + ruby-version: ${{ matrix.ruby_version }} bundler-cache: true - name: (Linter) Rubocop run: bundle exec rake rubocop