Skip to content

Commit

Permalink
CI: test rack-session head, test only latest JRuby (#1986)
Browse files Browse the repository at this point in the history
JRuby now stable, cleanup some old comments.
  • Loading branch information
dentarg committed Jan 5, 2024
1 parent 157e307 commit fa5a139
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 19 deletions.
16 changes: 9 additions & 7 deletions .github/workflows/test.yml
Expand Up @@ -11,14 +11,16 @@ permissions:

jobs:
rack-protection:
name: rack-protection (${{ matrix.ruby }}, Rack ${{ matrix.rack }})
name: rack-protection (${{ matrix.ruby }}, rack ${{ matrix.rack }}, rack-session ${{ matrix.rack_session }})
runs-on: ubuntu-latest
timeout-minutes: 5
strategy:
fail-fast: false
matrix:
rack:
- stable
rack_session:
- stable
ruby:
- "2.6"
- "2.7"
Expand All @@ -29,6 +31,10 @@ jobs:
- "jruby"
- "truffleruby"
- "ruby-head"
include:
# Rack
- { ruby: 3.2, rack: head, rack_session: stable }
- { ruby: 3.2, rack: stable, rack_session: head }
env:
rack: ${{ matrix.rack }}
steps:
Expand Down Expand Up @@ -57,7 +63,7 @@ jobs:
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
webhook: ${{ secrets.DISCORD_WEBHOOK }}
test:
sinatra:
name: ${{ matrix.ruby }} (Rack ${{ matrix.rack }}, Puma ${{ matrix.puma }}, Tilt ${{ matrix.tilt }})
runs-on: ubuntu-latest
timeout-minutes: 15
Expand All @@ -71,18 +77,14 @@ jobs:
tilt:
- stable
# Due to https://github.com/actions/runner/issues/849, we have to use quotes for '3.0'
ruby: [2.6, 2.7, '3.0', 3.1, 3.2, 3.3, truffleruby]
ruby: [2.6, 2.7, '3.0', 3.1, 3.2, 3.3, jruby, truffleruby]
include:
# Rack
- { ruby: 3.2, rack: head, puma: stable, tilt: stable, allow-failure: true }
# Puma
- { ruby: 3.2, rack: stable, puma: head, tilt: stable, allow-failure: true }
# Tilt
- { ruby: 3.2, rack: stable, puma: stable, tilt: head, allow-failure: true }
# Due to flaky tests, see https://github.com/sinatra/sinatra/pull/1870
- { ruby: jruby-9.3, rack: stable, puma: stable, tilt: stable, allow-failure: true }
# Due to https://github.com/jruby/jruby/issues/7647
- { ruby: jruby-9.4, rack: stable, puma: stable, tilt: stable, allow-failure: true }
# Never fail our build due to problems with head
- { ruby: ruby-head, rack: stable, puma: stable, tilt: stable, allow-failure: true }
- { ruby: jruby-head, rack: stable, puma: stable, tilt: stable, allow-failure: true }
Expand Down
8 changes: 0 additions & 8 deletions Gemfile
@@ -1,13 +1,5 @@
# frozen_string_literal: true

# Why use bundler?
# Well, not all development dependencies install on all rubies. Moreover, `gem
# install sinatra --development` doesn't work, as it will also try to install
# development dependencies of our dependencies, and those are not conflict free.
# So, here we are, `bundle install`.
#
# If you have issues with a gem: `bundle install --without-coffee-script`.

source 'https://rubygems.org'
gemspec

Expand Down
10 changes: 6 additions & 4 deletions rack-protection/Gemfile
@@ -1,16 +1,18 @@
# frozen_string_literal: true

source 'https://rubygems.org'
# encoding: utf-8
gemspec

gem 'rake'
gem 'rspec', '~> 3'
gem 'rack-test'

rack_version = ENV['rack'].to_s
rack_version = nil if rack_version.empty? || (rack_version == 'stable')
rack_version = { github: 'rack/rack' } if rack_version == 'head'
gem 'rack', rack_version

gemspec

gem 'rack-test'
rack_session_version = ENV['rack_session'].to_s
rack_session_version = nil if rack_session_version.empty? || (rack_session_version == 'stable')
rack_session_version = { github: 'rack/rack-session' } if rack_session_version == 'head'
gem 'rack-session', rack_session_version

0 comments on commit fa5a139

Please sign in to comment.