Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allows Rails 8, updates sqlite in Gemfile to match what CI runs #6091

Merged
merged 1 commit into from
Feb 4, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@ commands:
mkdir -p /tmp/dummy_extension
cd /tmp/dummy_extension
bundle init
bundle add rails -v "< 8.0" --skip-install
bundle add rails -v "< 8.1" --skip-install
bundle add sqlite3 -v "~> 2.0" --skip-install
test -n "<<parameters.extra_gems>>" && bundle add <<parameters.extra_gems>> --skip-install
bundle add solidus --path "$(ruby -e"puts File.expand_path ENV['CIRCLE_WORKING_DIRECTORY']")"
Expand Down Expand Up @@ -352,7 +352,7 @@ workflows:
{
parameters:
{
rails: ["7.0", "7.1", "7.2"],
rails: ["7.0", "7.1", "7.2", "8.0"],
ruby: ["3.1"],
database: ["mysql"],
paperclip: [true],
Expand All @@ -364,7 +364,7 @@ workflows:
{
parameters:
{
rails: ["7.0", "7.1", "7.2"],
rails: ["7.0", "7.1", "7.2", "8.0"],
ruby: ["3.1"],
database: ["postgres"],
paperclip: [false],
Expand All @@ -388,7 +388,7 @@ workflows:
{
parameters:
{
rails: ["7.2", "main"],
rails: ["7.2", "8.0", "main"],
ruby: ["3.3.5"],
database: ["sqlite"],
paperclip: [false],
Expand Down
2 changes: 1 addition & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ gemspec require: false
if /(stable|main)/.match? ENV['RAILS_VERSION']
gem 'rails', github: 'rails', require: false, branch: ENV['RAILS_VERSION']
else
gem 'rails', ENV['RAILS_VERSION'] || ['> 7.0', '< 8.0.0.beta1'], require: false
gem 'rails', ENV['RAILS_VERSION'] || ['> 7.0', '< 8.1.0.beta1'], require: false
end
# rubocop:enable Bundler/DuplicatedGem

Expand Down
19 changes: 15 additions & 4 deletions admin/app/components/solidus_admin/ui/forms/input/component.rb
Original file line number Diff line number Diff line change
Expand Up @@ -93,13 +93,24 @@ def call
with_content options_for_select(@attributes.delete(:choices), @attributes.delete(:value))
end

tag.public_send(
@tag,
content,
options = {
"data-controller": stimulus_id,
"data-#{stimulus_id}-custom-validity-value": @error.presence,
"data-action": "#{stimulus_id}#clearCustomValidity",
**@attributes
)
}

if tag.method(@tag).parameters.any? { |_type, name| name == :content }
tag.public_send(
@tag,
content,
**options
)
else
tag.public_send(
@tag,
**options
)
end
end
end
2 changes: 1 addition & 1 deletion api/spec/requests/spree/api/shipments_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ module Spree::Api
it 'returns proper error' do
subject
expect(response.status).to eq(422)
expect(json_response['exception']).to eq("param is missing or the value is empty: stock_location_id")
expect(json_response['exception']).to match(/param is missing or the value is empty( or invalid)?: stock_location_id/)
kennyadsl marked this conversation as resolved.
Show resolved Hide resolved
end
end
end
Expand Down
2 changes: 1 addition & 1 deletion api/spec/requests/spree/api/stock_items_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ module Spree::Api

it 'requires a stock_location_id to be passed as a parameter' do
get spree.api_stock_items_path
expect(json_response['exception']).to eq('param is missing or the value is empty: stock_location_id')
expect(json_response['exception']).to match(/param is missing or the value is empty( or invalid)?: stock_location_id/)
tvdeyen marked this conversation as resolved.
Show resolved Hide resolved
expect(response.status).to eq(422)
end

Expand Down
2 changes: 1 addition & 1 deletion core/solidus_core.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ Gem::Specification.new do |s|
actionmailer actionpack actionview activejob activemodel activerecord
activestorage activesupport railties
].each do |rails_dep|
s.add_dependency rails_dep, ['>= 7.0', '< 8.0.0.beta1']
s.add_dependency rails_dep, ['>= 7.0', '< 8.1.0.beta1']
end

s.add_dependency 'activemerchant', '~> 1.66'
Expand Down