Skip to content

Commit 0555c2c

Browse files
committed
CI: test against Rack v2 and v3
1 parent a9779b0 commit 0555c2c

2 files changed

Lines changed: 9 additions & 4 deletions

File tree

.github/workflows/test.yml

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,22 +4,27 @@ on: [push, pull_request]
44

55
jobs:
66
test:
7+
name: Test (Ruby ${{ matrix.ruby }}, Rack ${{ matrix.rack }})
78
runs-on: "ubuntu-latest"
89
continue-on-error: ${{ matrix.experimental }}
910
strategy:
1011
fail-fast: false
1112
matrix:
12-
ruby_version: ["2.6", "2.7", "3.0", "3.1", "3.2", "3.3", "3.4", "4.0"]
13+
ruby: ["2.6", "2.7", "3.0", "3.1", "3.2", "3.3", "3.4", "4.0"]
14+
rack: ["2", "3"]
1315
experimental: [false]
1416
include:
15-
- ruby_version: "ruby-head"
17+
- ruby: "ruby-head"
18+
rack: "3"
1619
experimental: true
20+
env:
21+
RACK_VERSION: ${{ matrix.rack }}
1722

1823
steps:
1924
- uses: actions/checkout@v6
2025
- uses: ruby/setup-ruby@v1
2126
with:
22-
ruby-version: ${{ matrix.ruby_version }}
27+
ruby-version: ${{ matrix.ruby }}
2328
bundler-cache: true
2429
- run: "bundle exec rubocop lib/ spec/"
2530
- run: "bundle exec rspec spec/ -b"

Gemfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ group :development do
88
end
99

1010
group :test do
11-
gem 'rack', '~> 2'
11+
gem 'rack', "~> #{ENV["RACK_VERSION"] || "3"}"
1212
gem 'rack-test', '~> 2'
1313
gem 'rspec', '~> 3.0', '>= 3.6.0'
1414
gem 'rspec-its', '~> 1.2'

0 commit comments

Comments
 (0)