Skip to content

Commit 0d40ea6

Browse files
authored
Add Rails 7.2 to CI (#671)
* Add Rails 7.2 to CI * Fix CI
1 parent 427fdfa commit 0d40ea6

7 files changed

+91
-2
lines changed

.github/workflows/build.yml

+27
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ jobs:
2828
gemfile:
2929
- rack_3
3030
- rack_2
31+
- rails_7_2
3132
- rails_7_1
3233
- rails_7_0
3334
- rails_6_1
@@ -38,6 +39,8 @@ jobs:
3839
- redis_5
3940
- redis_4
4041
- connection_pool_dalli
42+
- active_support_7_2_redis_cache_store
43+
- active_support_7_2_redis_cache_store_pooled
4144
- active_support_7_1_redis_cache_store
4245
- active_support_7_1_redis_cache_store_pooled
4346
- active_support_7_0_redis_cache_store
@@ -104,6 +107,30 @@ jobs:
104107
ruby: '2.6'
105108
- gemfile: active_support_7_1_redis_cache_store_pooled
106109
ruby: '2.5'
110+
- gemfile: rails_7_2
111+
ruby: '3.0'
112+
- gemfile: rails_7_2
113+
ruby: '2.7'
114+
- gemfile: rails_7_2
115+
ruby: '2.6'
116+
- gemfile: rails_7_2
117+
ruby: '2.5'
118+
- gemfile: active_support_7_2_redis_cache_store
119+
ruby: '3.0'
120+
- gemfile: active_support_7_2_redis_cache_store
121+
ruby: '2.7'
122+
- gemfile: active_support_7_2_redis_cache_store
123+
ruby: '2.6'
124+
- gemfile: active_support_7_2_redis_cache_store
125+
ruby: '2.5'
126+
- gemfile: active_support_7_2_redis_cache_store_pooled
127+
ruby: '3.0'
128+
- gemfile: active_support_7_2_redis_cache_store_pooled
129+
ruby: '2.7'
130+
- gemfile: active_support_7_2_redis_cache_store_pooled
131+
ruby: '2.6'
132+
- gemfile: active_support_7_2_redis_cache_store_pooled
133+
ruby: '2.5'
107134
env:
108135
BUNDLE_GEMFILE: gemfiles/${{ matrix.gemfile }}.gemfile
109136
steps:

Appraisals

+15
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,10 @@ appraise "rack_2" do
88
gem "rack", "~> 2.0"
99
end
1010

11+
appraise 'rails_7-2' do
12+
gem 'railties', '~> 7.2.0'
13+
end
14+
1115
appraise 'rails_7-1' do
1216
gem 'railties', '~> 7.1.0'
1317
end
@@ -49,6 +53,17 @@ appraise "connection_pool_dalli" do
4953
gem "dalli", "~> 3.0"
5054
end
5155

56+
appraise "active_support_7-2_redis_cache_store" do
57+
gem "activesupport", "~> 7.2.0"
58+
gem "redis", "~> 5.0"
59+
end
60+
61+
appraise "active_support_7-2_redis_cache_store_pooled" do
62+
gem "activesupport", "~> 7.2.0"
63+
gem "connection_pool", "~> 2.2"
64+
gem "redis", "~> 5.0"
65+
end
66+
5267
appraise "active_support_7-1_redis_cache_store" do
5368
gem "activesupport", "~> 7.1.0"
5469
gem "redis", "~> 5.0"
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# This file was generated by Appraisal
2+
3+
source "https://rubygems.org"
4+
5+
gem "activesupport", "~> 7.2.0"
6+
gem "redis", "~> 5.0"
7+
8+
group :maintenance, optional: true do
9+
gem "bake"
10+
gem "bake-gem"
11+
end
12+
13+
gemspec path: "../"
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
# This file was generated by Appraisal
2+
3+
source "https://rubygems.org"
4+
5+
gem "activesupport", "~> 7.2.0"
6+
gem "connection_pool", "~> 2.2"
7+
gem "redis", "~> 5.0"
8+
9+
group :maintenance, optional: true do
10+
gem "bake"
11+
gem "bake-gem"
12+
end
13+
14+
gemspec path: "../"

gemfiles/rails_7_2.gemfile

+12
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# This file was generated by Appraisal
2+
3+
source "https://rubygems.org"
4+
5+
gem "railties", "~> 7.2.0"
6+
7+
group :maintenance, optional: true do
8+
gem "bake"
9+
gem "bake-gem"
10+
end
11+
12+
gemspec path: "../"

spec/acceptance/stores/active_support_mem_cache_store_pooled_spec.rb

+5-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,11 @@
77

88
describe "ActiveSupport::Cache::MemCacheStore (pooled) as a cache backend" do
99
before do
10-
Rack::Attack.cache.store = ActiveSupport::Cache::MemCacheStore.new(pool_size: 2)
10+
Rack::Attack.cache.store = if ActiveSupport.gem_version >= Gem::Version.new("7.2.0")
11+
ActiveSupport::Cache::MemCacheStore.new(pool: true)
12+
else
13+
ActiveSupport::Cache::MemCacheStore.new(pool_size: 2)
14+
end
1115
end
1216

1317
after do

spec/acceptance/stores/active_support_redis_cache_store_pooled_spec.rb

+5-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,11 @@
1313

1414
describe "ActiveSupport::Cache::RedisCacheStore (pooled) as a cache backend" do
1515
before do
16-
Rack::Attack.cache.store = ActiveSupport::Cache::RedisCacheStore.new(pool_size: 2)
16+
Rack::Attack.cache.store = if ActiveSupport.gem_version >= Gem::Version.new("7.2.0")
17+
ActiveSupport::Cache::RedisCacheStore.new(pool: true)
18+
else
19+
ActiveSupport::Cache::RedisCacheStore.new(pool_size: 2)
20+
end
1721
end
1822

1923
after do

0 commit comments

Comments
 (0)