Skip to content

Commit 53f0823

Browse files
Drop support for EOL versions of Ruby and Rails
1 parent 6e54fe8 commit 53f0823

File tree

10 files changed

+86
-165
lines changed

10 files changed

+86
-165
lines changed

.github/workflows/test_suite.yml

Lines changed: 4 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -1,52 +1,28 @@
11
name: Test Suite
22

3-
on:
4-
push:
5-
branches: [main]
6-
pull_request:
7-
branches: [main]
8-
schedule:
9-
# 00:00 on the 1st of every month
10-
- cron: '0 0 1 * *'
3+
on: [push]
4+
115
jobs:
126
run-tests:
137
runs-on: ubuntu-latest
148
strategy:
159
fail-fast: false
1610
matrix:
1711
orm: [active_record, mongoid]
18-
rails: ["6.1", "7.0", "7.1"]
12+
rails: ["7.0", "7.1"]
1913
ruby: ["3.1", "3.2", "3.3", head]
2014
steps:
2115
- uses: actions/checkout@v4
2216
- uses: ruby/setup-ruby@v1
2317
with:
2418
ruby-version: ${{ matrix.ruby }}
25-
- uses: actions/cache@v4
26-
with:
27-
path: |
28-
**/bundle
29-
key:
30-
bundle-use-ruby-${{ matrix.ruby }}-rails-${{ matrix.rails }}-orm-${{
31-
matrix.orm }}-gemfile-${{
32-
hashFiles(format('**/gemfiles/rails_{0}.gemfile', matrix.rails))
33-
}}-gemspec-${{ hashFiles('**/devise-security.gemspec') }}
34-
- name: bundle install
35-
env:
36-
BUNDLE_GEMFILE: gemfiles/rails_${{ matrix.rails }}.gemfile
37-
run: |
38-
bundle config path vendor/bundle
39-
bundle install
19+
bundler-cache: true
4020
- name: Start MongoDB
4121
uses: supercharge/[email protected]
4222
if: ${{ matrix.orm == 'mongoid' }}
4323
- name:
4424
Tests for ORM ${{ matrix.orm }}, Rails ${{ matrix.rails }}, and Ruby
4525
${{ matrix.ruby }}
46-
env:
47-
BUNDLE_GEMFILE: gemfiles/rails_${{ matrix.rails }}.gemfile
48-
CI: true
49-
DEVISE_ORM: ${{ matrix.orm }}
5026
run: |
5127
bundle exec rake
5228
- name: Coveralls Parallel

Appraisals

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,5 @@
11
# frozen_string_literal: true
22

3-
appraise 'rails-6.1' do
4-
gem 'railties', '~> 6.1.0'
5-
gem 'minitest-rails', '~> 6.1.0'
6-
end
7-
83
appraise 'rails-7.0' do
94
gem 'railties', '~> 7.0.1' # Rails 7.0.0 and Ruby 3.1 are incompatible. See https://github.com/rails/rails/issues/43998 and https://github.com/rails/rails/pull/43951
105
gem 'minitest-rails', '~> 7.0.0'

Gemfile

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,17 +3,17 @@
33
source 'https://rubygems.org'
44
gemspec
55

6-
# Oldest Rails version getting security patches is 6.0
7-
gem 'minitest-rails', '~> 6.1.0'
8-
gem 'railties', '~> 6.1.7.8'
6+
# Oldest Rails version getting security patches is 7.0
7+
gem 'minitest-rails', '~> 7.0.0'
8+
gem 'railties', '~> 7.0.0'
99

1010
group :active_record do
1111
gem 'pg'
1212
gem 'sqlite3', '~> 1.4'
1313
end
1414

1515
group :mongoid do
16-
gem 'mongoid', '~> 8.0'
16+
gem 'mongoid', '~> 9.0'
1717

1818
group :test do
1919
gem 'database_cleaner-mongoid', '~> 2.0'

Gemfile.lock

Lines changed: 72 additions & 75 deletions
Original file line numberDiff line numberDiff line change
@@ -2,70 +2,76 @@ PATH
22
remote: .
33
specs:
44
devise-security (0.18.0)
5-
devise (>= 4.3.0)
5+
devise (>= 4.8.1)
66

77
GEM
88
remote: https://rubygems.org/
99
specs:
10-
actioncable (6.1.7.8)
11-
actionpack (= 6.1.7.8)
12-
activesupport (= 6.1.7.8)
10+
actioncable (7.0.8.6)
11+
actionpack (= 7.0.8.6)
12+
activesupport (= 7.0.8.6)
1313
nio4r (~> 2.0)
1414
websocket-driver (>= 0.6.1)
15-
actionmailbox (6.1.7.8)
16-
actionpack (= 6.1.7.8)
17-
activejob (= 6.1.7.8)
18-
activerecord (= 6.1.7.8)
19-
activestorage (= 6.1.7.8)
20-
activesupport (= 6.1.7.8)
15+
actionmailbox (7.0.8.6)
16+
actionpack (= 7.0.8.6)
17+
activejob (= 7.0.8.6)
18+
activerecord (= 7.0.8.6)
19+
activestorage (= 7.0.8.6)
20+
activesupport (= 7.0.8.6)
2121
mail (>= 2.7.1)
22-
actionmailer (6.1.7.8)
23-
actionpack (= 6.1.7.8)
24-
actionview (= 6.1.7.8)
25-
activejob (= 6.1.7.8)
26-
activesupport (= 6.1.7.8)
22+
net-imap
23+
net-pop
24+
net-smtp
25+
actionmailer (7.0.8.6)
26+
actionpack (= 7.0.8.6)
27+
actionview (= 7.0.8.6)
28+
activejob (= 7.0.8.6)
29+
activesupport (= 7.0.8.6)
2730
mail (~> 2.5, >= 2.5.4)
31+
net-imap
32+
net-pop
33+
net-smtp
2834
rails-dom-testing (~> 2.0)
29-
actionpack (6.1.7.8)
30-
actionview (= 6.1.7.8)
31-
activesupport (= 6.1.7.8)
32-
rack (~> 2.0, >= 2.0.9)
35+
actionpack (7.0.8.6)
36+
actionview (= 7.0.8.6)
37+
activesupport (= 7.0.8.6)
38+
rack (~> 2.0, >= 2.2.4)
3339
rack-test (>= 0.6.3)
3440
rails-dom-testing (~> 2.0)
3541
rails-html-sanitizer (~> 1.0, >= 1.2.0)
36-
actiontext (6.1.7.8)
37-
actionpack (= 6.1.7.8)
38-
activerecord (= 6.1.7.8)
39-
activestorage (= 6.1.7.8)
40-
activesupport (= 6.1.7.8)
42+
actiontext (7.0.8.6)
43+
actionpack (= 7.0.8.6)
44+
activerecord (= 7.0.8.6)
45+
activestorage (= 7.0.8.6)
46+
activesupport (= 7.0.8.6)
47+
globalid (>= 0.6.0)
4148
nokogiri (>= 1.8.5)
42-
actionview (6.1.7.8)
43-
activesupport (= 6.1.7.8)
49+
actionview (7.0.8.6)
50+
activesupport (= 7.0.8.6)
4451
builder (~> 3.1)
4552
erubi (~> 1.4)
4653
rails-dom-testing (~> 2.0)
4754
rails-html-sanitizer (~> 1.1, >= 1.2.0)
48-
activejob (6.1.7.8)
49-
activesupport (= 6.1.7.8)
55+
activejob (7.0.8.6)
56+
activesupport (= 7.0.8.6)
5057
globalid (>= 0.3.6)
51-
activemodel (6.1.7.8)
52-
activesupport (= 6.1.7.8)
53-
activerecord (6.1.7.8)
54-
activemodel (= 6.1.7.8)
55-
activesupport (= 6.1.7.8)
56-
activestorage (6.1.7.8)
57-
actionpack (= 6.1.7.8)
58-
activejob (= 6.1.7.8)
59-
activerecord (= 6.1.7.8)
60-
activesupport (= 6.1.7.8)
58+
activemodel (7.0.8.6)
59+
activesupport (= 7.0.8.6)
60+
activerecord (7.0.8.6)
61+
activemodel (= 7.0.8.6)
62+
activesupport (= 7.0.8.6)
63+
activestorage (7.0.8.6)
64+
actionpack (= 7.0.8.6)
65+
activejob (= 7.0.8.6)
66+
activerecord (= 7.0.8.6)
67+
activesupport (= 7.0.8.6)
6168
marcel (~> 1.0)
6269
mini_mime (>= 1.1.0)
63-
activesupport (6.1.7.8)
70+
activesupport (7.0.8.6)
6471
concurrent-ruby (~> 1.0, >= 1.0.2)
6572
i18n (>= 1.6, < 2)
6673
minitest (>= 5.1)
6774
tzinfo (~> 2.0)
68-
zeitwerk (~> 2.3)
6975
appraisal (2.5.0)
7076
bundler
7177
rake
@@ -76,7 +82,7 @@ GEM
7682
bcrypt (3.1.20)
7783
benchmark (0.3.0)
7884
bigdecimal (3.1.8)
79-
bson (5.0.1)
85+
bson (5.0.2)
8086
builder (3.3.0)
8187
byebug (11.1.3)
8288
coderay (1.1.3)
@@ -152,16 +158,15 @@ GEM
152158
mini_mime (1.1.5)
153159
mini_portile2 (2.8.7)
154160
minitest (5.25.1)
155-
minitest-rails (6.1.1)
161+
minitest-rails (7.0.1)
156162
minitest (~> 5.10)
157-
railties (~> 6.1.0)
158-
mongo (2.20.1)
163+
railties (~> 7.0.0)
164+
mongo (2.21.0)
159165
bson (>= 4.14.1, < 6.0.0)
160-
mongoid (8.1.5)
161-
activemodel (>= 5.1, < 7.2, != 7.0.0)
166+
mongoid (9.0.3)
167+
activemodel (>= 5.1, < 8.1, != 7.0.0)
162168
concurrent-ruby (>= 1.0.5, < 2.0)
163169
mongo (>= 2.18.0, < 3.0.0)
164-
ruby2_keywords (~> 0.0.5)
165170
mutex_m (0.2.0)
166171
net-imap (0.4.15)
167172
date
@@ -203,21 +208,20 @@ GEM
203208
rack (~> 2.2, >= 2.2.4)
204209
rack-test (2.1.0)
205210
rack (>= 1.3)
206-
rails (6.1.7.8)
207-
actioncable (= 6.1.7.8)
208-
actionmailbox (= 6.1.7.8)
209-
actionmailer (= 6.1.7.8)
210-
actionpack (= 6.1.7.8)
211-
actiontext (= 6.1.7.8)
212-
actionview (= 6.1.7.8)
213-
activejob (= 6.1.7.8)
214-
activemodel (= 6.1.7.8)
215-
activerecord (= 6.1.7.8)
216-
activestorage (= 6.1.7.8)
217-
activesupport (= 6.1.7.8)
211+
rails (7.0.8.6)
212+
actioncable (= 7.0.8.6)
213+
actionmailbox (= 7.0.8.6)
214+
actionmailer (= 7.0.8.6)
215+
actionpack (= 7.0.8.6)
216+
actiontext (= 7.0.8.6)
217+
actionview (= 7.0.8.6)
218+
activejob (= 7.0.8.6)
219+
activemodel (= 7.0.8.6)
220+
activerecord (= 7.0.8.6)
221+
activestorage (= 7.0.8.6)
222+
activesupport (= 7.0.8.6)
218223
bundler (>= 1.15.0)
219-
railties (= 6.1.7.8)
220-
sprockets-rails (>= 2.0.0)
224+
railties (= 7.0.8.6)
221225
rails-controller-testing (1.0.5)
222226
actionpack (>= 5.0.1.rc1)
223227
actionview (>= 5.0.1.rc1)
@@ -234,12 +238,13 @@ GEM
234238
railties (>= 6.0.0, < 8)
235239
rails_email_validator (0.1.4)
236240
activemodel (>= 3.0.0)
237-
railties (6.1.7.8)
238-
actionpack (= 6.1.7.8)
239-
activesupport (= 6.1.7.8)
241+
railties (7.0.8.6)
242+
actionpack (= 7.0.8.6)
243+
activesupport (= 7.0.8.6)
240244
method_source
241245
rake (>= 12.2)
242246
thor (~> 1.0)
247+
zeitwerk (~> 2.5)
243248
rainbow (3.1.1)
244249
rake (13.2.1)
245250
regexp_parser (2.9.2)
@@ -293,7 +298,6 @@ GEM
293298
rubocop (>= 1.52.0, < 2.0)
294299
rubocop-ast (>= 1.31.1, < 2.0)
295300
ruby-progressbar (1.13.0)
296-
ruby2_keywords (0.0.5)
297301
simplecov (0.22.0)
298302
docile (~> 1.1)
299303
simplecov-html (~> 0.11)
@@ -319,13 +323,6 @@ GEM
319323
solargraph-arc (0.3.0)
320324
activesupport (>= 5.0)
321325
solargraph (~> 0.44.2)
322-
sprockets (4.2.1)
323-
concurrent-ruby (~> 1.0)
324-
rack (>= 2.2.4, < 4)
325-
sprockets-rails (3.5.2)
326-
actionpack (>= 6.1)
327-
activesupport (>= 6.1)
328-
sprockets (>= 3.0.0)
329326
sqlite3 (1.7.3)
330327
mini_portile2 (~> 2.8.0)
331328
strscan (3.1.0)
@@ -362,15 +359,15 @@ DEPENDENCIES
362359
i18n-tasks
363360
m
364361
minitest
365-
minitest-rails (~> 6.1.0)
366-
mongoid (~> 8.0)
362+
minitest-rails (~> 7.0.0)
363+
mongoid (~> 9.0)
367364
mutex_m
368365
omniauth
369366
pg
370367
pry-rescue
371368
rails-controller-testing
372369
rails_email_validator
373-
railties (~> 6.1.7.8)
370+
railties (~> 7.0.0)
374371
rubocop
375372
rubocop-minitest
376373
rubocop-rails

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ automated mass creation and brute forcing of accounts harder)
3737

3838
## Getting started
3939

40-
Devise Security works with Devise on Rails >= 5.2. You can add it to your
40+
Devise Security works with Devise on Rails >= 7.0. You can add it to your
4141
Gemfile after you successfully set up Devise (see
4242
[Devise documentation](https://github.com/heartcombo/devise)) with:
4343

@@ -326,7 +326,7 @@ end
326326
## Requirements
327327

328328
- Devise (<https://github.com/heartcombo/devise>)
329-
- Rails 5.2 onwards (<http://github.com/rails/rails>)
329+
- Rails 7.0 onwards (<http://github.com/rails/rails>)
330330
- recommendations:
331331
- `autocomplete-off` (<http://github.com/phatworx/autocomplete-off>)
332332
- `easy_captcha` (<http://github.com/phatworx/easy_captcha>)

devise-security.gemspec

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,9 +27,9 @@ Gem::Specification.new do |s|
2727
s.files = Dir['README.md', 'LICENSE.txt', 'lib/**/*', 'app/**/*', 'config/**/*']
2828
s.test_files = Dir['test/**/*']
2929
s.require_paths = ['lib']
30-
s.required_ruby_version = '>= 2.3.0'
30+
s.required_ruby_version = '>= 3.1.0'
3131

32-
s.add_runtime_dependency 'devise', '>= 4.3.0'
32+
s.add_runtime_dependency 'devise', '>= 4.8.1'
3333

3434
s.add_development_dependency 'appraisal'
3535
s.add_development_dependency 'bundler'

gemfiles/rails_6.1.gemfile

Lines changed: 0 additions & 27 deletions
This file was deleted.

gemfiles/rails_7.0.gemfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ group :active_record do
1313
end
1414

1515
group :mongoid do
16-
gem "mongoid", "~> 8.0"
16+
gem "mongoid", "~> 9.0"
1717

1818
group :test do
1919
gem "database_cleaner-mongoid", "~> 2.0"

0 commit comments

Comments
 (0)