Skip to content

Commit 522d1b9

Browse files
tnirimjoehaines
authored andcommitted
Add rack 3.0 to the text matrix only in Ruby 2.4.0+
Signed-off-by: Takuya Noguchi <takninnovationresearch@gmail.com>
1 parent f1b1c58 commit 522d1b9

1 file changed

Lines changed: 9 additions & 2 deletions

File tree

Gemfile

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -60,8 +60,15 @@ if ruby_version >= Gem::Version.new('2.2.0')
6060
gem 'redis'
6161
end
6262

63-
# rack 2.2.0 dropped support for Ruby 2.2
64-
gem 'rack', ruby_version < Gem::Version.new('2.3.0') ? '< 2.2.0' : '~> 2.2'
63+
if ruby_version < Gem::Version.new('2.3.0')
64+
# rack 2.2.0 dropped support for Ruby 2.2
65+
gem 'rack', '< 2.2.0'
66+
elsif ruby_version < Gem::Version.new('2.4.0')
67+
# rack 3.0.0 dropped support for Ruby 2.3
68+
gem 'rack', '~> 2.2'
69+
else
70+
gem 'rack', '~> 3.0'
71+
end
6572

6673
# rack-protection 3.0.0 requires Ruby 2.6+
6774
gem 'rack-protection', '< 3.0.0' if ruby_version < Gem::Version.new('2.6.0')

0 commit comments

Comments
 (0)