diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index fc5ac940..a7eeca90 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -16,7 +16,6 @@ jobs: fail-fast: false matrix: ruby: - - 2.2 - 2.3 - 2.4 - 2.5 @@ -25,7 +24,6 @@ jobs: - 3.0 - 3.1 - 3.2 - # - truffleruby-head gemfile: # These are located in the gemfiles/ folder - rails42 @@ -57,15 +55,6 @@ jobs: exclude: # Following https://www.fastruby.io/blog/ruby/rails/versions/compatibility-table.html # to decide what to include. - - { ruby: 2.2, gemfile: rails60 } - - { ruby: 2.2, gemfile: rails60_boc } - - { ruby: 2.2, gemfile: rails60_haml } - - { ruby: 2.2, gemfile: rails61 } - - { ruby: 2.2, gemfile: rails61_boc } - - { ruby: 2.2, gemfile: rails61_haml } - - { ruby: 2.2, gemfile: rails70 } - - { ruby: 2.2, gemfile: rails70_boc } - - { ruby: 2.2, gemfile: rails70_haml } - { ruby: 2.3, gemfile: rails42 } - { ruby: 2.3, gemfile: rails42_boc } - { ruby: 2.3, gemfile: rails42_haml } @@ -177,14 +166,9 @@ jobs: - { ruby: 3.2, gemfile: rails60 } - { ruby: 3.2, gemfile: rails60_boc } - { ruby: 3.2, gemfile: rails60_haml } - # - { ruby: truffleruby-head, gemfile: rails42_boc } - # - { ruby: truffleruby-head, gemfile: rails50_boc } - # - { ruby: truffleruby-head, gemfile: rails51_boc } - # - { ruby: truffleruby-head, gemfile: rails52_boc } - # - { ruby: truffleruby-head, gemfile: rails60_boc } - # - { ruby: truffleruby-head, gemfile: rails61_boc } - # - { ruby: truffleruby-head, gemfile: rails70_boc } - # - { ruby: truffleruby-head, gemfile: rack_boc } + + env: + BUNDLE_GEMFILE: gemfiles/${{ matrix.gemfile }}.gemfile steps: @@ -194,23 +178,62 @@ jobs: uses: ruby/setup-ruby@v1 with: ruby-version: ${{ matrix.ruby }} + bundler-cache: true - - uses: actions/cache@v2 + - name: Bundle install + run: | + bundle config path vendor/bundle + bundle install --jobs 4 --retry 3 + + - name: RSpec + run: bundle exec rspec -f doc --color + + test_older: + # Ruby 2.2 has a known issue on Ubuntu 22, so we must test it on Ubuntu 20 + # https://github.com/ruby/setup-ruby/issues/496 + runs-on: ubuntu-20.04 + strategy: + fail-fast: false + matrix: + ruby: + - 2.2 + gemfile: + # These are located in the gemfiles/ folder + - rails42 + - rails50 + - rails51 + - rails52 + - rails42_haml + - rails50_haml + - rails51_haml + - rails52_haml + - rails42_boc + - rails50_boc + - rails51_boc + - rails52_boc + - rack + - rack_boc + # - pry09 + # - pry10 + # - pry11 + + env: + BUNDLE_GEMFILE: gemfiles/${{ matrix.gemfile }}.gemfile + + steps: + + - uses: actions/checkout@v2 + + - name: Set up Ruby + uses: ruby/setup-ruby@v1 with: - path: gemfiles/vendor/bundle - key: v3-${{ runner.os }}-branch-${{ github.ref }}-ruby-${{ matrix.ruby }}-gemfile-${{ matrix.gemfile }}-${{ hashFiles(format('gemfiles/{0}.gemfile', matrix.gemfile)) }} - restore-keys: | - v3-${{ runner.os }}-branch-${{ github.ref }}-ruby-${{ matrix.ruby }}-gemfile-${{ matrix.gemfile }} - v3-${{ runner.os }}-branch-master-ruby-${{ matrix.ruby }}-gemfile-${{ matrix.gemfile }} + ruby-version: ${{ matrix.ruby }} + bundler-cache: true - name: Bundle install run: | bundle config path vendor/bundle bundle install --jobs 4 --retry 3 - env: - BUNDLE_GEMFILE: gemfiles/${{ matrix.gemfile }}.gemfile - name: RSpec run: bundle exec rspec -f doc --color - env: - BUNDLE_GEMFILE: gemfiles/${{ matrix.gemfile }}.gemfile