Skip to content

Commit

Permalink
Merge pull request #2360 from TonyCTHsu/feature/sinatra-3
Browse files Browse the repository at this point in the history
Support Sinatra 3
  • Loading branch information
TonyCTHsu authored Nov 11, 2022
2 parents af002cd + 1514a71 commit b478593
Show file tree
Hide file tree
Showing 16 changed files with 2,430 additions and 132 deletions.
54 changes: 45 additions & 9 deletions Appraisals
Original file line number Diff line number Diff line change
Expand Up @@ -123,13 +123,17 @@ if ruby_version?('2.1')
gem 'sequel', '~> 4.0', '< 4.37'
gem 'shoryuken'
gem 'sidekiq', '~> 3.5.4'
gem 'sinatra', '1.4.5'
gem 'sqlite3', '~> 1.3.6'
gem 'sucker_punch'
gem 'timers', '< 4.2'
gem 'typhoeus'
end

appraise 'sinatra' do
gem 'sinatra'
gem 'rack-test'
end

appraise 'core-old' do
gem 'dogstatsd-ruby', '~> 4'
end
Expand Down Expand Up @@ -301,14 +305,18 @@ elsif ruby_version?('2.2')
gem 'sequel'
gem 'shoryuken'
gem 'sidekiq'
gem 'sinatra'
gem 'sneakers', '>= 2.12.0'
gem 'sqlite3', '~> 1.3.6'
gem 'sucker_punch'
gem 'typhoeus'
gem 'que', '>= 1.0.0'
end

appraise 'sinatra' do
gem 'sinatra'
gem 'rack-test'
end

appraise 'core-old' do
gem 'dogstatsd-ruby', '~> 4'
end
Expand Down Expand Up @@ -492,14 +500,18 @@ elsif ruby_version?('2.3')
gem 'sequel'
gem 'shoryuken'
gem 'sidekiq'
gem 'sinatra'
gem 'sneakers', '>= 2.12.0'
gem 'sqlite3', '~> 1.3.6'
gem 'sucker_punch'
gem 'typhoeus'
gem 'que', '>= 1.0.0'
end

appraise 'sinatra' do
gem 'sinatra'
gem 'rack-test'
end

appraise 'contrib-old' do
gem 'elasticsearch', '< 8.0.0' # Dependency elasticsearch-transport renamed to elastic-transport in >= 8.0
gem 'faraday', '0.17'
Expand Down Expand Up @@ -617,14 +629,18 @@ elsif ruby_version?('2.4')
gem 'sequel'
gem 'shoryuken'
gem 'sidekiq'
gem 'sinatra'
gem 'sneakers', '>= 2.12.0'
gem 'sqlite3', '~> 1.3.6'
gem 'sucker_punch'
gem 'typhoeus'
gem 'que', '>= 1.0.0'
end

appraise 'sinatra' do
gem 'sinatra'
gem 'rack-test'
end

appraise 'contrib-old' do
gem 'elasticsearch', '< 8.0.0' # Dependency elasticsearch-transport renamed to elastic-transport in >= 8.0
gem 'faraday', '0.17'
Expand Down Expand Up @@ -872,7 +888,6 @@ elsif ruby_version?('2.5')
gem 'sequel'
gem 'shoryuken'
gem 'sidekiq'
gem 'sinatra', '>= 1.4'
gem 'sneakers', '>= 2.12.0'
gem 'sqlite3', '~> 1.4.1', platform: :ruby
gem 'jdbc-sqlite3', '>= 3.28', platform: :jruby
Expand All @@ -881,6 +896,11 @@ elsif ruby_version?('2.5')
gem 'que', '>= 1.0.0'
end

appraise 'sinatra' do
gem 'sinatra'
gem 'rack-test'
end

appraise 'contrib-old' do
gem 'dalli', '< 3.0.0'
gem 'elasticsearch', '< 8.0.0' # Dependency elasticsearch-transport renamed to elastic-transport in >= 8.0
Expand Down Expand Up @@ -1103,7 +1123,6 @@ elsif ruby_version?('2.6')
gem 'sequel'
gem 'shoryuken'
gem 'sidekiq'
gem 'sinatra', '>= 1.4'
gem 'sneakers', '>= 2.12.0'
gem 'sqlite3', '~> 1.4.1', platform: :ruby
gem 'jdbc-sqlite3', '>= 3.28', platform: :jruby
Expand All @@ -1112,6 +1131,11 @@ elsif ruby_version?('2.6')
gem 'que', '>= 1.0.0'
end

appraise 'sinatra' do
gem 'sinatra', '>= 3'
gem 'rack-test'
end

appraise 'contrib-old' do
gem 'dalli', '< 3.0.0'
gem 'elasticsearch', '< 8.0.0' # Dependency elasticsearch-transport renamed to elastic-transport in >= 8.0
Expand Down Expand Up @@ -1314,14 +1338,18 @@ elsif ruby_version?('2.7')
gem 'semantic_logger', '~> 4.0'
gem 'shoryuken'
gem 'sidekiq'
gem 'sinatra'
gem 'sneakers', '>= 2.12.0'
gem 'sqlite3', '~> 1.4.1'
gem 'sucker_punch'
gem 'typhoeus'
gem 'que', '>= 1.0.0'
end

appraise 'sinatra' do
gem 'sinatra', '>= 3'
gem 'rack-test'
end

appraise 'contrib-old' do
gem 'dalli', '< 3.0.0'
gem 'elasticsearch', '< 8.0.0' # Dependency elasticsearch-transport renamed to elastic-transport in >= 8.0
Expand Down Expand Up @@ -1430,7 +1458,6 @@ elsif ruby_version?('3.0') || ruby_version?('3.1')
gem 'sequel'
gem 'shoryuken'
gem 'sidekiq'
gem 'sinatra'
gem 'sneakers', '>= 2.12.0'
gem 'sqlite3', '>= 1.4.2'
gem 'sucker_punch'
Expand All @@ -1439,6 +1466,11 @@ elsif ruby_version?('3.0') || ruby_version?('3.1')
gem 'net-smtp'
end

appraise 'sinatra' do
gem 'sinatra', '>= 3'
gem 'rack-test'
end

appraise 'contrib-old' do
gem 'dalli', '< 3.0.0'
gem 'elasticsearch', '< 8.0.0' # Dependency elasticsearch-transport renamed to elastic-transport in >= 8.0
Expand Down Expand Up @@ -1546,7 +1578,6 @@ elsif ruby_version?('3.2')
gem 'sequel'
gem 'shoryuken'
gem 'sidekiq'
gem 'sinatra'
gem 'sneakers', '>= 2.12.0'
gem 'sqlite3', '>= 1.4.2'
gem 'sucker_punch'
Expand All @@ -1556,6 +1587,11 @@ elsif ruby_version?('3.2')
gem 'nokogiri', platform: :ruby # TODO: binary gem has max ruby version constraint excluding previews, switch to using minimum version constraint once a non-3.2-excluding binary gem is released
end

appraise 'sinatra' do
gem 'sinatra', '>= 3'
gem 'rack-test'
end

appraise 'contrib-old' do
gem 'dalli', '< 3.0.0'
gem 'elasticsearch', '< 8.0.0' # Dependency elasticsearch-transport renamed to elastic-transport in >= 8.0
Expand Down
4 changes: 3 additions & 1 deletion Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -314,7 +314,6 @@ task :ci do
declare '✅ 2.1 / ✅ 2.2 / ✅ 2.3 / ✅ 2.4 / ✅ 2.5 / ✅ 2.6 / ✅ 2.7 / ✅ 3.0 / ✅ 3.1 / ✅ 3.2 / ✅ jruby' => 'bundle exec appraisal contrib rake spec:sequel'
declare '❌ 2.1 / ✅ 2.2 / ✅ 2.3 / ✅ 2.4 / ✅ 2.5 / ✅ 2.6 / ✅ 2.7 / ✅ 3.0 / ✅ 3.1 / ✅ 3.2 / ✅ jruby' => 'bundle exec appraisal contrib rake spec:shoryuken'
declare '✅ 2.1 / ✅ 2.2 / ✅ 2.3 / ✅ 2.4 / ✅ 2.5 / ✅ 2.6 / ✅ 2.7 / ✅ 3.0 / ✅ 3.1 / ✅ 3.2 / ✅ jruby' => 'bundle exec appraisal contrib rake spec:sidekiq'
declare '✅ 2.1 / ✅ 2.2 / ✅ 2.3 / ✅ 2.4 / ✅ 2.5 / ✅ 2.6 / ✅ 2.7 / ✅ 3.0 / ✅ 3.1 / ✅ 3.2 / ✅ jruby' => 'bundle exec appraisal contrib rake spec:sinatra'
declare '❌ 2.1 / ✅ 2.2 / ✅ 2.3 / ✅ 2.4 / ✅ 2.5 / ✅ 2.6 / ✅ 2.7 / ✅ 3.0 / ✅ 3.1 / ✅ 3.2 / ✅ jruby' => 'bundle exec appraisal contrib rake spec:sneakers'
declare '✅ 2.1 / ✅ 2.2 / ✅ 2.3 / ✅ 2.4 / ✅ 2.5 / ✅ 2.6 / ✅ 2.7 / ✅ 3.0 / ✅ 3.1 / ✅ 3.2 / ✅ jruby' => 'bundle exec appraisal contrib rake spec:sucker_punch'
declare '✅ 2.1 / ✅ 2.2 / ✅ 2.3 / ✅ 2.4 / ✅ 2.5 / ✅ 2.6 / ✅ 2.7 / ✅ 3.0 / ✅ 3.1 / ✅ 3.2 / ✅ jruby' => 'bundle exec appraisal contrib rake spec:suite'
Expand Down Expand Up @@ -376,6 +375,9 @@ task :ci do
# explicitly test Hanami compatability
declare '❌ 2.1 / ❌ 2.2 / ✅ 2.3 / ✅ 2.4 / ✅ 2.5 / ✅ 2.6 / ✅ 2.7 / ❌ 3.0 / ❌ 3.1 / ❌ 3.2 / ❌ jruby' => 'bundle exec appraisal hanami-1 rake spec:hanami'

# explicitly test Sinatra compatability
declare '✅ 2.1 / ✅ 2.2 / ✅ 2.3 / ✅ 2.4 / ✅ 2.5 / ✅ 2.6 / ✅ 2.7 / ✅ 3.0 / ✅ 3.1 / ✅ 3.2 / ✅ jruby' => 'bundle exec appraisal sinatra rake spec:sinatra'

# explicitly test resque-2x compatability
declare '❌ 2.1 / ❌ 2.2 / ✅ 2.3 / ✅ 2.4 / ✅ 2.5 / ✅ 2.6 / ✅ 2.7 / ✅ 3.0 / ✅ 3.1 / ✅ 3.2 / ✅ jruby' => 'bundle exec appraisal resque2-redis3 rake spec:resque'
declare '❌ 2.1 / ❌ 2.2 / ✅ 2.3 / ✅ 2.4 / ✅ 2.5 / ✅ 2.6 / ✅ 2.7 / ✅ 3.0 / ✅ 3.1 / ✅ 3.2 / ✅ jruby' => 'bundle exec appraisal resque2-redis4 rake spec:resque'
Expand Down
180 changes: 180 additions & 0 deletions gemfiles/jruby_9.2.18.0_sinatra.gemfile.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit b478593

Please sign in to comment.