diff --git a/.github/workflows/actions.yml b/.github/workflows/actions.yml index 3c3a945..3f47772 100644 --- a/.github/workflows/actions.yml +++ b/.github/workflows/actions.yml @@ -11,7 +11,7 @@ jobs: strategy: matrix: ruby: ['2.7', '3.0'] - rails: ['5.2', '6.0', '6.1', '7.0'] + rails: ['5.2', '6.0', '6.1', '7.0', '7.1'] exclude: - ruby: '3.0' rails: '5.2' diff --git a/Gemfile.lock b/Gemfile.lock index 6973021..09e0fe6 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -2,7 +2,7 @@ PATH remote: . specs: ar_after_transaction (0.8.0) - activerecord (>= 5.2.0, < 7.1) + activerecord (>= 5.2.0, < 7.2) GEM remote: https://rubygems.org/ @@ -182,4 +182,4 @@ DEPENDENCIES wwtd BUNDLED WITH - 2.3.4 + 2.3.12 diff --git a/ar_after_transaction.gemspec b/ar_after_transaction.gemspec index a44350b..160877c 100644 --- a/ar_after_transaction.gemspec +++ b/ar_after_transaction.gemspec @@ -9,7 +9,7 @@ Gem::Specification.new 'ar_after_transaction', ARAfterTransaction::VERSION do |s s.homepage = 'http://github.com/grosser/ar_after_transaction' s.files = `git ls-files lib Readme.md`.split("\n") s.required_ruby_version = '>= 2.6.0' - s.add_runtime_dependency 'activerecord', '>= 5.2.0', '< 7.1' + s.add_runtime_dependency 'activerecord', '>= 5.2.0', '< 7.2' s.add_development_dependency 'bump' s.add_development_dependency 'rails' s.add_development_dependency 'rake' diff --git a/gemfiles/rails5.2.gemfile.lock b/gemfiles/rails5.2.gemfile.lock index abd4b41..1528106 100644 --- a/gemfiles/rails5.2.gemfile.lock +++ b/gemfiles/rails5.2.gemfile.lock @@ -2,7 +2,7 @@ PATH remote: .. specs: ar_after_transaction (0.8.0) - activerecord (>= 5.2.0, < 7.1) + activerecord (>= 5.2.0, < 7.2) GEM remote: https://rubygems.org/ diff --git a/gemfiles/rails6.0.gemfile.lock b/gemfiles/rails6.0.gemfile.lock index 9d8a39c..9ded9dd 100644 --- a/gemfiles/rails6.0.gemfile.lock +++ b/gemfiles/rails6.0.gemfile.lock @@ -2,7 +2,7 @@ PATH remote: .. specs: ar_after_transaction (0.8.0) - activerecord (>= 5.2.0, < 7.1) + activerecord (>= 5.2.0, < 7.2) GEM remote: https://rubygems.org/ diff --git a/gemfiles/rails6.1.gemfile.lock b/gemfiles/rails6.1.gemfile.lock index 6be7401..154ac4e 100644 --- a/gemfiles/rails6.1.gemfile.lock +++ b/gemfiles/rails6.1.gemfile.lock @@ -2,7 +2,7 @@ PATH remote: .. specs: ar_after_transaction (0.8.0) - activerecord (>= 5.2.0, < 7.1) + activerecord (>= 5.2.0, < 7.2) GEM remote: https://rubygems.org/ diff --git a/gemfiles/rails7.0.gemfile.lock b/gemfiles/rails7.0.gemfile.lock index e3f1c12..1628318 100644 --- a/gemfiles/rails7.0.gemfile.lock +++ b/gemfiles/rails7.0.gemfile.lock @@ -2,7 +2,7 @@ PATH remote: .. specs: ar_after_transaction (0.8.0) - activerecord (>= 5.2.0, < 7.1) + activerecord (>= 5.2.0, < 7.2) GEM remote: https://rubygems.org/ diff --git a/gemfiles/rails7.1.gemfile b/gemfiles/rails7.1.gemfile new file mode 100644 index 0000000..fb519ca --- /dev/null +++ b/gemfiles/rails7.1.gemfile @@ -0,0 +1,7 @@ +# frozen_string_literal: true + +source 'https://rubygems.org' + +gem 'activerecord', '~>7.1.0' + +gemspec path: '../' diff --git a/gemfiles/rails7.1.gemfile.lock b/gemfiles/rails7.1.gemfile.lock new file mode 100644 index 0000000..16e5543 --- /dev/null +++ b/gemfiles/rails7.1.gemfile.lock @@ -0,0 +1,217 @@ +PATH + remote: .. + specs: + ar_after_transaction (0.8.0) + activerecord (>= 5.2.0, < 7.2) + +GEM + remote: https://rubygems.org/ + specs: + actioncable (7.1.0) + actionpack (= 7.1.0) + activesupport (= 7.1.0) + nio4r (~> 2.0) + websocket-driver (>= 0.6.1) + zeitwerk (~> 2.6) + actionmailbox (7.1.0) + actionpack (= 7.1.0) + activejob (= 7.1.0) + activerecord (= 7.1.0) + activestorage (= 7.1.0) + activesupport (= 7.1.0) + mail (>= 2.7.1) + net-imap + net-pop + net-smtp + actionmailer (7.1.0) + actionpack (= 7.1.0) + actionview (= 7.1.0) + activejob (= 7.1.0) + activesupport (= 7.1.0) + mail (~> 2.5, >= 2.5.4) + net-imap + net-pop + net-smtp + rails-dom-testing (~> 2.2) + actionpack (7.1.0) + actionview (= 7.1.0) + activesupport (= 7.1.0) + nokogiri (>= 1.8.5) + rack (>= 2.2.4) + rack-session (>= 1.0.1) + rack-test (>= 0.6.3) + rails-dom-testing (~> 2.2) + rails-html-sanitizer (~> 1.6) + actiontext (7.1.0) + actionpack (= 7.1.0) + activerecord (= 7.1.0) + activestorage (= 7.1.0) + activesupport (= 7.1.0) + globalid (>= 0.6.0) + nokogiri (>= 1.8.5) + actionview (7.1.0) + activesupport (= 7.1.0) + builder (~> 3.1) + erubi (~> 1.11) + rails-dom-testing (~> 2.2) + rails-html-sanitizer (~> 1.6) + activejob (7.1.0) + activesupport (= 7.1.0) + globalid (>= 0.3.6) + activemodel (7.1.0) + activesupport (= 7.1.0) + activerecord (7.1.0) + activemodel (= 7.1.0) + activesupport (= 7.1.0) + timeout (>= 0.4.0) + activestorage (7.1.0) + actionpack (= 7.1.0) + activejob (= 7.1.0) + activerecord (= 7.1.0) + activesupport (= 7.1.0) + marcel (~> 1.0) + activesupport (7.1.0) + base64 + bigdecimal + concurrent-ruby (~> 1.0, >= 1.0.2) + connection_pool (>= 2.2.5) + drb + i18n (>= 1.6, < 2) + minitest (>= 5.1) + mutex_m + tzinfo (~> 2.0) + base64 (0.1.1) + bigdecimal (3.1.4) + builder (3.2.4) + bump (0.10.0) + concurrent-ruby (1.2.2) + connection_pool (2.4.1) + crass (1.0.6) + date (3.3.3) + diff-lcs (1.5.0) + drb (2.1.1) + ruby2_keywords + erubi (1.12.0) + globalid (1.2.1) + activesupport (>= 6.1) + i18n (1.14.1) + concurrent-ruby (~> 1.0) + io-console (0.6.0) + irb (1.8.1) + rdoc + reline (>= 0.3.8) + loofah (2.21.3) + crass (~> 1.0.2) + nokogiri (>= 1.12.0) + mail (2.8.1) + mini_mime (>= 0.1.1) + net-imap + net-pop + net-smtp + marcel (1.0.2) + mini_mime (1.1.5) + minitest (5.20.0) + mutex_m (0.1.2) + net-imap (0.4.0) + date + net-protocol + net-pop (0.1.2) + net-protocol + net-protocol (0.2.1) + timeout + net-smtp (0.4.0) + net-protocol + nio4r (2.5.9) + nokogiri (1.15.4-arm64-darwin) + racc (~> 1.4) + nokogiri (1.15.4-x86_64-linux) + racc (~> 1.4) + psych (5.1.0) + stringio + racc (1.7.1) + rack (3.0.8) + rack-session (2.0.0) + rack (>= 3.0.0) + rack-test (2.1.0) + rack (>= 1.3) + rackup (2.1.0) + rack (>= 3) + webrick (~> 1.8) + rails (7.1.0) + actioncable (= 7.1.0) + actionmailbox (= 7.1.0) + actionmailer (= 7.1.0) + actionpack (= 7.1.0) + actiontext (= 7.1.0) + actionview (= 7.1.0) + activejob (= 7.1.0) + activemodel (= 7.1.0) + activerecord (= 7.1.0) + activestorage (= 7.1.0) + activesupport (= 7.1.0) + bundler (>= 1.15.0) + railties (= 7.1.0) + rails-dom-testing (2.2.0) + activesupport (>= 5.0.0) + minitest + nokogiri (>= 1.6) + rails-html-sanitizer (1.6.0) + loofah (~> 2.21) + nokogiri (~> 1.14) + railties (7.1.0) + actionpack (= 7.1.0) + activesupport (= 7.1.0) + irb + rackup (>= 1.0.0) + rake (>= 12.2) + thor (~> 1.0, >= 1.2.2) + zeitwerk (~> 2.6) + rake (13.0.6) + rdoc (6.5.0) + psych (>= 4.0.0) + reline (0.3.9) + io-console (~> 0.5) + rspec (3.12.0) + rspec-core (~> 3.12.0) + rspec-expectations (~> 3.12.0) + rspec-mocks (~> 3.12.0) + rspec-core (3.12.2) + rspec-support (~> 3.12.0) + rspec-expectations (3.12.3) + diff-lcs (>= 1.2.0, < 2.0) + rspec-support (~> 3.12.0) + rspec-mocks (3.12.6) + diff-lcs (>= 1.2.0, < 2.0) + rspec-support (~> 3.12.0) + rspec-support (3.12.1) + ruby2_keywords (0.0.5) + sqlite3 (1.6.6-arm64-darwin) + sqlite3 (1.6.6-x86_64-linux) + stringio (3.0.8) + thor (1.2.2) + timeout (0.4.0) + tzinfo (2.0.6) + concurrent-ruby (~> 1.0) + webrick (1.8.1) + websocket-driver (0.7.6) + websocket-extensions (>= 0.1.0) + websocket-extensions (0.1.5) + wwtd (1.4.1) + zeitwerk (2.6.12) + +PLATFORMS + arm64-darwin-21 + x86_64-linux + +DEPENDENCIES + activerecord (~> 7.1.0) + ar_after_transaction! + bump + rails + rake + rspec (~> 3) + sqlite3 + wwtd + +BUNDLED WITH + 2.3.12 diff --git a/spec/after_initialize_spec.rb b/spec/after_initialize_spec.rb index 11c5966..2d2b909 100644 --- a/spec/after_initialize_spec.rb +++ b/spec/after_initialize_spec.rb @@ -39,7 +39,9 @@ class Application < ::Rails::Application end end - Rack::Session::Cookie.send(:define_method, :warn) { |_| } # silence secret warning + if defined?(Rack::Session::Cookie) + Rack::Session::Cookie.send(:define_method, :warn) { |_| } # silence secret warning + end ARAfterTransaction::Application.initialize! # initialize app class AnExpectedError < RuntimeError; end