From 77c1572ef1cb5e4e21c91a89313427d549c724f3 Mon Sep 17 00:00:00 2001 From: Jon Rowe Date: Fri, 8 Nov 2024 18:41:55 +0000 Subject: [PATCH 1/4] changelog for #2808 --- Changelog.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Changelog.md b/Changelog.md index 6bebf46bb..a512048ef 100644 --- a/Changelog.md +++ b/Changelog.md @@ -7,6 +7,8 @@ Enhancements: `have_broadcast`. (Simon Fish, #2795) * Comment out `infer_spec_type_from_file_location!` in newly generated `rails_helper.rb` files. (Jon Rowe, #2804) +* Allow turning off active job / mailer argument validation. + (Oli Peate, #2808) Bug Fixes: From d0249d448bb0101812980165ff1ebed36ef0df7e Mon Sep 17 00:00:00 2001 From: Jon Rowe Date: Fri, 8 Nov 2024 18:45:15 +0000 Subject: [PATCH 2/4] v7.0.2 --- Changelog.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Changelog.md b/Changelog.md index a512048ef..8fbe3a90f 100644 --- a/Changelog.md +++ b/Changelog.md @@ -1,5 +1,5 @@ ### Development -[Full Changelog](https://github.com/rspec/rspec-rails/compare/v7.0.1...main) +[Full Changelog](https://github.com/rspec/rspec-rails/compare/v7.0.2...main) Enhancements: @@ -10,6 +10,9 @@ Enhancements: * Allow turning off active job / mailer argument validation. (Oli Peate, #2808) +### 7.0.2 / 2024-11-08 +[Full Changelog](https://github.com/rspec/rspec-rails/compare/v7.0.1...v7.0.2) + Bug Fixes: * Fix issue with `have_enqueued_mail` when jobs were incorrectly matched due From 72d59aaa8a3e116bfae76600672476b8e3a1a32e Mon Sep 17 00:00:00 2001 From: Jon Rowe Date: Fri, 8 Nov 2024 18:53:35 +0000 Subject: [PATCH 3/4] v7.1.0 --- Changelog.md | 5 ++++- README.md | 5 +++-- lib/rspec/rails/version.rb | 2 +- 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/Changelog.md b/Changelog.md index 8fbe3a90f..d5993bcb3 100644 --- a/Changelog.md +++ b/Changelog.md @@ -1,5 +1,8 @@ ### Development -[Full Changelog](https://github.com/rspec/rspec-rails/compare/v7.0.2...main) +[Full Changelog](https://github.com/rspec/rspec-rails/compare/v7.1.0...main) + +### 7.1.0 / 2024-11-08 +[Full Changelog](https://github.com/rspec/rspec-rails/compare/v7.0.1...v7.0.2) Enhancements: diff --git a/README.md b/README.md index e000e0140..ff589d0ff 100644 --- a/README.md +++ b/README.md @@ -32,8 +32,9 @@ According to [RSpec Rails new versioning strategy][] use: ## Installation -**IMPORTANT** This README / branch refers to the current development build. -See the [`7-0-maintenance` branch on Github](https://github.com/rspec/rspec-rails/tree/7-0-maintenance) if you want or require the latest stable release. +**IMPORTANT** This README / branch refers to the 7.1.x stable release series, only bugfixes from this series will +be added here. See the [`main` branch on Github](https://github.com/rspec/rspec-rails/tree/main) if you want or +require the latest unstable features. 1. Add `rspec-rails` to **both** the `:development` and `:test` groups of your app’s `Gemfile`: diff --git a/lib/rspec/rails/version.rb b/lib/rspec/rails/version.rb index 96fe5d6c7..e03e64027 100644 --- a/lib/rspec/rails/version.rb +++ b/lib/rspec/rails/version.rb @@ -3,7 +3,7 @@ module Rails # Version information for RSpec Rails. module Version # Current version of RSpec Rails, in semantic versioning format. - STRING = '7.1.0.pre' + STRING = '7.2.0.pre' end end end From 92db634970b90fc9963a5e28e9d1dca5a5c9bf5e Mon Sep 17 00:00:00 2001 From: Jon Rowe Date: Fri, 8 Nov 2024 18:56:42 +0000 Subject: [PATCH 4/4] Add Rails 8 to build --- .github/workflows/ci.yml | 10 +++++++++- Gemfile-rails-dependencies | 23 ++++++++--------------- example_app_generator/generate_app.rb | 2 +- 3 files changed, 18 insertions(+), 17 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ad118a06b..9b0473130 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -23,7 +23,7 @@ jobs: - uses: actions/checkout@v4 - uses: ruby/setup-ruby@v1 with: - ruby-version: '3.0' + ruby-version: '3.3' - run: script/update_rubygems_and_install_bundler - run: bundle install --standalone - run: bundle binstubs --all @@ -44,6 +44,14 @@ jobs: env: RAILS_VERSION: 'main' + # Rails 8.0 builds >= 3.2 + - ruby: 3.3 + env: + RAILS_VERSION: '~> 8.0.0' + - ruby: 3.2 + env: + RAILS_VERSION: '~> 8.0.0' + # Rails 7.2 builds >= 3.1 - ruby: 3.3 env: diff --git a/Gemfile-rails-dependencies b/Gemfile-rails-dependencies index 0d08d7663..48e5b7d6d 100644 --- a/Gemfile-rails-dependencies +++ b/Gemfile-rails-dependencies @@ -11,13 +11,15 @@ def add_net_gems_dependency end end -def add_sqlite3_gem_dependency - # sqlite3 is an optional, unspecified, dependency and Rails 6.0 only supports `~> 1.4` +def add_sqlite3_gem_dependency(rails_version) + # sqlite3 is an optional, unspecified, dependency and Rails 8.0 only supports `~> 2.0` if RUBY_VERSION.to_f < 3 # sqlite3 1.7.x doesn't work on all platforms for Ruby 2.x gem 'sqlite3', '~> 1.4', '< 1.7', platforms: [:ruby] + elsif rails_version.to_f >= 8 + gem 'sqlite3', '~> 2.0', platforms: [:ruby] else - gem 'sqlite3', '~> 1.4', platforms: [:ruby] + gem 'sqlite3', '~> 1.7', platforms: [:ruby] end end @@ -29,21 +31,12 @@ when /main/ gem 'activerecord-jdbcsqlite3-adapter', git: 'https://github.com/jruby/activerecord-jdbc-adapter', platforms: [:jruby] gem 'selenium-webdriver', require: false - # Rails 8 requires 2.0.0 gem 'sqlite3', '~> 2.0', platforms: [:ruby] -when /stable$/ - gem_list = %w[rails railties actionmailer actionpack activerecord activesupport activejob actionview] - gem 'activerecord-jdbcsqlite3-adapter', git: 'https://github.com/jruby/activerecord-jdbc-adapter', platforms: [:jruby] - - gem_list.each do |rails_gem| - gem rails_gem, :git => "https://github.com/rails/rails.git", :branch => version - end - add_sqlite3_gem_dependency when nil, false, "" - gem "rails", "~> 7.0.0" + gem "rails", "~> 8.0.0" gem 'activerecord-jdbcsqlite3-adapter', platforms: [:jruby] gem 'selenium-webdriver', require: false - add_sqlite3_gem_dependency + gem 'sqlite3', '~> 2.0', platforms: [:ruby] else version_number = version.split(' ').last add_net_gems_dependency if version_number < '7.0' @@ -58,5 +51,5 @@ else else gem 'selenium-webdriver', require: false end - add_sqlite3_gem_dependency + add_sqlite3_gem_dependency(version_number) end diff --git a/example_app_generator/generate_app.rb b/example_app_generator/generate_app.rb index aaa727663..77e99bffc 100644 --- a/example_app_generator/generate_app.rb +++ b/example_app_generator/generate_app.rb @@ -35,7 +35,7 @@ elsif Rails::VERSION::STRING > '8' gsub_file "Gemfile", /.*gem..sqlite3.*/, "gem 'sqlite3', '~> 2.0'" else - gsub_file "Gemfile", /.*gem..sqlite3.*/, "gem 'sqlite3', '~> 1.4'" + gsub_file "Gemfile", /.*gem..sqlite3.*/, "gem 'sqlite3', '~> 1.7'" end # remove webdrivers