Skip to content

Commit

Permalink
update workflow to run tests w/ appraisals
Browse files Browse the repository at this point in the history
  • Loading branch information
LeipeLeon committed Dec 8, 2023
1 parent f9f08b3 commit 8b7090c
Showing 1 changed file with 84 additions and 22 deletions.
106 changes: 84 additions & 22 deletions .github/workflows/ruby.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,37 +18,99 @@ permissions:

jobs:
test:
runs-on: ubuntu-22.04
runs-on: ubuntu-latest
name: Ruby ${{ matrix.ruby }} w/ ${{ matrix.gemfile }}
strategy:
fail-fast: false
matrix:
ruby: [2.3, 2.4, 2.5, 2.6, 2.7]
rails: ["4.1", "4.2", "5.0", "5.2.3", "6.0"]
exclude:
- ruby: "2.4"
rails: "4.1"
- ruby: "2.4"
rails: "4.2"
- ruby: "2.4"
rails: "6.0"
- ruby: "2.5"
rails: "4.1"
- ruby: "2.5"
rails: "4.2"
- ruby: "2.6"
rails: "4.1"
- ruby: "2.6"
rails: "4.2"
- ruby: "2.7"
rails: "4.1"
- ruby: "2.7"
rails: "4.2"
ruby:
- "2.3"
- "2.4"
- "2.5"
- "2.6"
- "2.7"
- "3.0"
- "3.1"
# - "3.2"
gemfile:
- "activesupport-3.2"
- "activesupport-4.0"
- "activesupport-4.1"
- "activesupport-4.2"
- "activesupport-5.0"
- "activesupport-5.1"
- "activesupport-5.2"
- "activesupport-6.0"
- "activesupport-6.1"
- "activesupport-7.0"
- "activesupport-7.1"
# exclude:
# - ruby: "2.4"
# gemfile: "activesupport-4.1"
# - ruby: "2.4"
# gemfile: "activesupport-4.2"
# - ruby: "2.4"
# gemfile: "activesupport-5.0"
# - ruby: "2.4"
# gemfile: "activesupport-5.1"
# - ruby: "2.4"
# gemfile: "activesupport-6.0"

# - ruby: "2.5"
# gemfile: "activesupport-4.1"
# - ruby: "2.5"
# gemfile: "activesupport-4.2"
# - ruby: "2.5"
# gemfile: "activesupport-5.0"
# - ruby: "2.5"
# gemfile: "activesupport-5.1"
# - ruby: "2.5"
# gemfile: "activesupport-5.2"

# - ruby: "2.6"
# gemfile: "activesupport-4.1"
# - ruby: "2.6"
# gemfile: "activesupport-4.2"
# - ruby: "2.6"
# gemfile: "activesupport-5.0"
# - ruby: "2.6"
# gemfile: "activesupport-5.1"
# - ruby: "2.6"
# gemfile: "activesupport-5.2"
# - ruby: "2.6"
# gemfile: "activesupport-6.0"
# - ruby: "2.6"
# gemfile: "activesupport-7.0"
# - ruby: "2.6"
# gemfile: "activesupport-7.1"
# - ruby: "2.7"
# gemfile: "activesupport-4.1"
# - ruby: "2.7"
# gemfile: "activesupport-4.2"
steps:
- uses: actions/checkout@v4
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
bundler-cache: true # runs 'bundle install' and caches installed gems automatically
- name: Configure bundler
run: |
bundle config path vendor/bundle
- name: Create bundler lockfile
run: |
bundle lock
- uses: actions/cache@v3
with:
# NOTE: Bundler expands the path relative to the gemfile, not the
# current directory.
path: ./gemfiles/vendor/bundle
key: bundled-gems-${{ runner.os }}-ruby-${{ matrix.ruby }}-${{ matrix.gemfile }}-${{ hashFiles( 'gemfiles/*.lock' ) }}
restore-keys: |
bundled-gems-${{ runner.os }}-ruby-${{ matrix.ruby }}-${{ matrix.gemfile }}-
bundled-gems-${{ runner.os }}-ruby-${{ matrix.ruby }}-
- name: Install gems
run: |
bundle install --jobs 4
- name: Run tests
run: bundle exec rake

0 comments on commit 8b7090c

Please sign in to comment.