Skip to content

Commit 438d935

Browse files
committed
Add separate tests for 7.0 and 7.1
1 parent 1b62405 commit 438d935

File tree

7 files changed

+350
-11
lines changed

7 files changed

+350
-11
lines changed

.github/workflows/ruby.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ jobs:
2020
fail-fast: false
2121
matrix:
2222
ruby-version: ['2.7', '3.1', '3.2']
23-
gemfile: [ rails_6.1, rails_7.0 ]
23+
gemfile: [ rails_6.1, rails_7.0, rails7.1 ]
2424
env:
2525
BUNDLE_GEMFILE: ${{ github.workspace }}/gemfiles/${{ matrix.gemfile }}.gemfile
2626
steps:

README.md

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -229,7 +229,9 @@ The gem is available as open source under the terms of the [MIT License](https:/
229229
Run:
230230

231231
```bash
232-
$ bundle
232+
# Set the version of rails we want to follow
233+
export BUNDLE_GEMFILE=gemfiles/rails_7.0.gemfile
234+
bundle install
233235
```
234236

235237
from the root directory. This will also install the gems required by the dummy application found at `spec/dummy`.
@@ -260,16 +262,18 @@ Ensure to update `lib/rpi_auth/version.rb` when publishing a new version.
260262
### Testing
261263

262264
```bash
263-
$ bundle exec rspec
265+
$ bundle exec --gemfile gemfiles/rails_7.0.gemfile rspec
264266
```
265267

266268
#### Testing with different versions of Rails
267269

268-
This Gem should work with Rails 6.1+, but the `Gemfile.lock` is tracking Rails 7 at the moment. To test Rails 6.1, you'll want to use `gemfiles/rails_6.1.gemfile` as your gemfile, and then run rspec using that.
270+
This Gem should work with Rails 6.1+. To test Rails 6.1, you'll want to use `gemfiles/rails_6.1.gemfile` as your gemfile, and then run rspec using that.
269271

270272
```
271-
bundle install --gemfile gemfiles/rails_6.1.gemfile
272-
bundle exec --gemfile gemfiles/rails_6.1.gemfile rspec
273+
# Set the version of rails we want to follow
274+
export BUNDLE_GEMFILE=gemfiles/rails_6.1.gemfile
275+
bundle install
276+
bundle exec rspec
273277
```
274278

275279
## Releasing

gemfiles/rails_6.1.gemfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
source 'https://rubygems.org'
44

5-
gem 'rails', '~> 6.1'
5+
gem 'rails', '~> 6.1.0'
66

77
# Specify your gem's dependencies in rpi_auth.gemspec.
88
gemspec path: '../'

gemfiles/rails_7.0.gemfile

Lines changed: 0 additions & 1 deletion
This file was deleted.

gemfiles/rails_7.0.gemfile

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# frozen_string_literal: true
2+
3+
source 'https://rubygems.org'
4+
5+
gem 'rails', '~> 7.0.0'
6+
7+
# Specify your gem's dependencies in rpi_auth.gemspec.
8+
if File.dirname(__FILE__).end_with?('gemfiles')
9+
gemspec path: '../'
10+
else
11+
gemspec
12+
end

gemfiles/rails_7.0.gemfile.lock

Lines changed: 0 additions & 1 deletion
This file was deleted.

gemfiles/rails_7.0.gemfile.lock

Lines changed: 325 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,325 @@
1+
PATH
2+
remote: ..
3+
specs:
4+
rpi_auth (3.4.0)
5+
omniauth-rails_csrf_protection (~> 1.0.0)
6+
omniauth_openid_connect (~> 0.7.1)
7+
rails (>= 6.1.4)
8+
9+
GEM
10+
remote: https://rubygems.org/
11+
specs:
12+
actioncable (7.0.8)
13+
actionpack (= 7.0.8)
14+
activesupport (= 7.0.8)
15+
nio4r (~> 2.0)
16+
websocket-driver (>= 0.6.1)
17+
actionmailbox (7.0.8)
18+
actionpack (= 7.0.8)
19+
activejob (= 7.0.8)
20+
activerecord (= 7.0.8)
21+
activestorage (= 7.0.8)
22+
activesupport (= 7.0.8)
23+
mail (>= 2.7.1)
24+
net-imap
25+
net-pop
26+
net-smtp
27+
actionmailer (7.0.8)
28+
actionpack (= 7.0.8)
29+
actionview (= 7.0.8)
30+
activejob (= 7.0.8)
31+
activesupport (= 7.0.8)
32+
mail (~> 2.5, >= 2.5.4)
33+
net-imap
34+
net-pop
35+
net-smtp
36+
rails-dom-testing (~> 2.0)
37+
actionpack (7.0.8)
38+
actionview (= 7.0.8)
39+
activesupport (= 7.0.8)
40+
rack (~> 2.0, >= 2.2.4)
41+
rack-test (>= 0.6.3)
42+
rails-dom-testing (~> 2.0)
43+
rails-html-sanitizer (~> 1.0, >= 1.2.0)
44+
actiontext (7.0.8)
45+
actionpack (= 7.0.8)
46+
activerecord (= 7.0.8)
47+
activestorage (= 7.0.8)
48+
activesupport (= 7.0.8)
49+
globalid (>= 0.6.0)
50+
nokogiri (>= 1.8.5)
51+
actionview (7.0.8)
52+
activesupport (= 7.0.8)
53+
builder (~> 3.1)
54+
erubi (~> 1.4)
55+
rails-dom-testing (~> 2.0)
56+
rails-html-sanitizer (~> 1.1, >= 1.2.0)
57+
activejob (7.0.8)
58+
activesupport (= 7.0.8)
59+
globalid (>= 0.3.6)
60+
activemodel (7.0.8)
61+
activesupport (= 7.0.8)
62+
activerecord (7.0.8)
63+
activemodel (= 7.0.8)
64+
activesupport (= 7.0.8)
65+
activestorage (7.0.8)
66+
actionpack (= 7.0.8)
67+
activejob (= 7.0.8)
68+
activerecord (= 7.0.8)
69+
activesupport (= 7.0.8)
70+
marcel (~> 1.0)
71+
mini_mime (>= 1.1.0)
72+
activesupport (7.0.8)
73+
concurrent-ruby (~> 1.0, >= 1.0.2)
74+
i18n (>= 1.6, < 2)
75+
minitest (>= 5.1)
76+
tzinfo (~> 2.0)
77+
aes_key_wrap (1.1.0)
78+
ast (2.4.2)
79+
attr_required (1.0.2)
80+
base64 (0.2.0)
81+
bindata (2.4.15)
82+
builder (3.2.4)
83+
byebug (11.1.3)
84+
coderay (1.1.3)
85+
concurrent-ruby (1.2.3)
86+
crass (1.0.6)
87+
date (3.3.4)
88+
diff-lcs (1.5.0)
89+
docile (1.4.0)
90+
email_validator (2.2.4)
91+
activemodel
92+
erubi (1.12.0)
93+
faraday (2.8.1)
94+
base64
95+
faraday-net_http (>= 2.0, < 3.1)
96+
ruby2_keywords (>= 0.0.4)
97+
faraday-follow_redirects (0.3.0)
98+
faraday (>= 1, < 3)
99+
faraday-net_http (3.0.2)
100+
ffi (1.16.3)
101+
globalid (1.2.1)
102+
activesupport (>= 6.1)
103+
hashie (5.0.0)
104+
i18n (1.14.1)
105+
concurrent-ruby (~> 1.0)
106+
json (2.7.1)
107+
json-jwt (1.16.5)
108+
activesupport (>= 4.2)
109+
aes_key_wrap
110+
base64
111+
bindata
112+
faraday (~> 2.0)
113+
faraday-follow_redirects
114+
language_server-protocol (3.17.0.3)
115+
listen (3.8.0)
116+
rb-fsevent (~> 0.10, >= 0.10.3)
117+
rb-inotify (~> 0.9, >= 0.9.10)
118+
loofah (2.22.0)
119+
crass (~> 1.0.2)
120+
nokogiri (>= 1.12.0)
121+
mail (2.8.1)
122+
mini_mime (>= 0.1.1)
123+
net-imap
124+
net-pop
125+
net-smtp
126+
marcel (1.0.2)
127+
method_source (1.0.0)
128+
mini_mime (1.1.5)
129+
mini_portile2 (2.8.5)
130+
minitest (5.21.1)
131+
net-imap (0.4.9.1)
132+
date
133+
net-protocol
134+
net-pop (0.1.2)
135+
net-protocol
136+
net-protocol (0.2.2)
137+
timeout
138+
net-smtp (0.4.0.1)
139+
net-protocol
140+
nio4r (2.7.0)
141+
nokogiri (1.15.5)
142+
mini_portile2 (~> 2.8.2)
143+
racc (~> 1.4)
144+
omniauth (2.1.2)
145+
hashie (>= 3.4.6)
146+
rack (>= 2.2.3)
147+
rack-protection
148+
omniauth-rails_csrf_protection (1.0.1)
149+
actionpack (>= 4.2)
150+
omniauth (~> 2.0)
151+
omniauth_openid_connect (0.7.1)
152+
omniauth (>= 1.9, < 3)
153+
openid_connect (~> 2.2)
154+
openid_connect (2.3.0)
155+
activemodel
156+
attr_required (>= 1.0.0)
157+
email_validator
158+
faraday (~> 2.0)
159+
faraday-follow_redirects
160+
json-jwt (>= 1.16)
161+
mail
162+
rack-oauth2 (~> 2.2)
163+
swd (~> 2.0)
164+
tzinfo
165+
validate_url
166+
webfinger (~> 2.0)
167+
parallel (1.24.0)
168+
parser (3.3.0.4)
169+
ast (~> 2.4.1)
170+
racc
171+
pry (0.14.2)
172+
coderay (~> 1.1)
173+
method_source (~> 1.0)
174+
pry-byebug (3.10.1)
175+
byebug (~> 11.0)
176+
pry (>= 0.13, < 0.15)
177+
public_suffix (5.0.4)
178+
puma (6.4.2)
179+
nio4r (~> 2.0)
180+
racc (1.7.3)
181+
rack (2.2.8)
182+
rack-oauth2 (2.2.1)
183+
activesupport
184+
attr_required
185+
faraday (~> 2.0)
186+
faraday-follow_redirects
187+
json-jwt (>= 1.11.0)
188+
rack (>= 2.1.0)
189+
rack-protection (3.2.0)
190+
base64 (>= 0.1.0)
191+
rack (~> 2.2, >= 2.2.4)
192+
rack-test (2.1.0)
193+
rack (>= 1.3)
194+
rails (7.0.8)
195+
actioncable (= 7.0.8)
196+
actionmailbox (= 7.0.8)
197+
actionmailer (= 7.0.8)
198+
actionpack (= 7.0.8)
199+
actiontext (= 7.0.8)
200+
actionview (= 7.0.8)
201+
activejob (= 7.0.8)
202+
activemodel (= 7.0.8)
203+
activerecord (= 7.0.8)
204+
activestorage (= 7.0.8)
205+
activesupport (= 7.0.8)
206+
bundler (>= 1.15.0)
207+
railties (= 7.0.8)
208+
rails-dom-testing (2.2.0)
209+
activesupport (>= 5.0.0)
210+
minitest
211+
nokogiri (>= 1.6)
212+
rails-html-sanitizer (1.6.0)
213+
loofah (~> 2.21)
214+
nokogiri (~> 1.14)
215+
railties (7.0.8)
216+
actionpack (= 7.0.8)
217+
activesupport (= 7.0.8)
218+
method_source
219+
rake (>= 12.2)
220+
thor (~> 1.0)
221+
zeitwerk (~> 2.5)
222+
rainbow (3.1.1)
223+
rake (13.1.0)
224+
rb-fsevent (0.11.2)
225+
rb-inotify (0.10.1)
226+
ffi (~> 1.0)
227+
regexp_parser (2.9.0)
228+
rexml (3.2.6)
229+
rspec-core (3.12.2)
230+
rspec-support (~> 3.12.0)
231+
rspec-expectations (3.12.3)
232+
diff-lcs (>= 1.2.0, < 2.0)
233+
rspec-support (~> 3.12.0)
234+
rspec-mocks (3.12.6)
235+
diff-lcs (>= 1.2.0, < 2.0)
236+
rspec-support (~> 3.12.0)
237+
rspec-rails (6.1.0)
238+
actionpack (>= 6.1)
239+
activesupport (>= 6.1)
240+
railties (>= 6.1)
241+
rspec-core (~> 3.12)
242+
rspec-expectations (~> 3.12)
243+
rspec-mocks (~> 3.12)
244+
rspec-support (~> 3.12)
245+
rspec-support (3.12.1)
246+
rspec_junit_formatter (0.6.0)
247+
rspec-core (>= 2, < 4, != 2.12.0)
248+
rubocop (1.60.0)
249+
json (~> 2.3)
250+
language_server-protocol (>= 3.17.0)
251+
parallel (~> 1.10)
252+
parser (>= 3.3.0.2)
253+
rainbow (>= 2.2.2, < 4.0)
254+
regexp_parser (>= 1.8, < 3.0)
255+
rexml (>= 3.2.5, < 4.0)
256+
rubocop-ast (>= 1.30.0, < 2.0)
257+
ruby-progressbar (~> 1.7)
258+
unicode-display_width (>= 2.4.0, < 3.0)
259+
rubocop-ast (1.30.0)
260+
parser (>= 3.2.1.0)
261+
rubocop-capybara (2.20.0)
262+
rubocop (~> 1.41)
263+
rubocop-factory_bot (2.25.1)
264+
rubocop (~> 1.41)
265+
rubocop-performance (1.20.2)
266+
rubocop (>= 1.48.1, < 2.0)
267+
rubocop-ast (>= 1.30.0, < 2.0)
268+
rubocop-rails (2.23.1)
269+
activesupport (>= 4.2.0)
270+
rack (>= 1.1)
271+
rubocop (>= 1.33.0, < 2.0)
272+
rubocop-ast (>= 1.30.0, < 2.0)
273+
rubocop-rspec (2.26.1)
274+
rubocop (~> 1.40)
275+
rubocop-capybara (~> 2.17)
276+
rubocop-factory_bot (~> 2.22)
277+
ruby-progressbar (1.13.0)
278+
ruby2_keywords (0.0.5)
279+
simplecov (0.22.0)
280+
docile (~> 1.1)
281+
simplecov-html (~> 0.11)
282+
simplecov_json_formatter (~> 0.1)
283+
simplecov-html (0.12.3)
284+
simplecov_json_formatter (0.1.4)
285+
swd (2.0.3)
286+
activesupport (>= 3)
287+
attr_required (>= 0.0.5)
288+
faraday (~> 2.0)
289+
faraday-follow_redirects
290+
thor (1.3.0)
291+
timeout (0.4.1)
292+
tzinfo (2.0.6)
293+
concurrent-ruby (~> 1.0)
294+
unicode-display_width (2.5.0)
295+
validate_url (1.0.15)
296+
activemodel (>= 3.0.0)
297+
public_suffix
298+
webfinger (2.1.3)
299+
activesupport
300+
faraday (~> 2.0)
301+
faraday-follow_redirects
302+
websocket-driver (0.7.6)
303+
websocket-extensions (>= 0.1.0)
304+
websocket-extensions (0.1.5)
305+
zeitwerk (2.6.12)
306+
307+
PLATFORMS
308+
ruby
309+
310+
DEPENDENCIES
311+
listen
312+
pry-byebug
313+
puma
314+
rails (~> 7.0.0)
315+
rpi_auth!
316+
rspec-rails
317+
rspec_junit_formatter
318+
rubocop
319+
rubocop-performance
320+
rubocop-rails
321+
rubocop-rspec
322+
simplecov
323+
324+
BUNDLED WITH
325+
2.1.4

0 commit comments

Comments
 (0)