Skip to content

Commit

Permalink
Merge pull request #1359 from Shopify/ruby3
Browse files Browse the repository at this point in the history
Update to Ruby 3
  • Loading branch information
gonzaloriestra committed Jan 31, 2022
2 parents 615aa3a + 1e17295 commit 5931d7e
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 17 deletions.
5 changes: 2 additions & 3 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
name: Ruby ${{ matrix.version }}
strategy:
matrix:
version: [2.5, 2.6, 2.7]
version: ['2.6', '2.7', '3.0']

steps:
- uses: actions/checkout@v2
Expand All @@ -24,7 +24,7 @@ jobs:
key: ${{ runner.os }}-npm-${{ hashFiles('**/package-lock.json') }}
- name: Set up Ruby ${{ matrix.version }}
uses: ruby/setup-ruby@v1
with:
with:
ruby-version: ${{ matrix.version }}
bundler-cache: true
- name: Set up Node
Expand All @@ -38,4 +38,3 @@ jobs:
run: |
yarn test
bundle exec rake test
2 changes: 1 addition & 1 deletion .ruby-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
2.5.0
3.0.3
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
Unreleased
----------
* Support Rails 7 [#1354](https://github.com/Shopify/shopify_app/pull/1354)
* Fix webhooks handling in Ruby 3 [#1342](https://github.com/Shopify/shopify_app/pull/1342)
* Update to Ruby 3 and drop support to Ruby 2.5 [#1359](https://github.com/Shopify/shopify_app/pull/1359)

18.0.4 (Jan 27, 2022)
----------
Expand Down
2 changes: 1 addition & 1 deletion shopify_app.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ Gem::Specification.new do |s|
s.author = "Shopify"
s.summary = 'This gem is used to get quickly started with the Shopify API'

s.required_ruby_version = ">= 2.5"
s.required_ruby_version = ">= 2.6"

s.metadata['allowed_push_host'] = 'https://rubygems.org'

Expand Down
20 changes: 8 additions & 12 deletions test/shopify_app/configuration_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -25,19 +25,15 @@ class ConfigurationTest < ActiveSupport::TestCase
end

test "can set root_url which affects login_url" do
# TODO: drop `rubocop:todo Style/RedundantBegin` together with Ruby 2.4 support
# As this style is supported since Ruby 2.5 (see https://bugs.ruby-lang.org/issues/12906)
begin # rubocop:todo Style/RedundantBegin
original_root = ShopifyApp.configuration.root_url

ShopifyApp.configure do |config|
config.root_url = "/nested"
end

assert_equal("/nested/login", ShopifyApp.configuration.login_url)
ensure
ShopifyApp.configuration.root_url = original_root
original_root = ShopifyApp.configuration.root_url

ShopifyApp.configure do |config|
config.root_url = "/nested"
end

assert_equal("/nested/login", ShopifyApp.configuration.login_url)
ensure
ShopifyApp.configuration.root_url = original_root
end

test "defaults to myshopify_domain" do
Expand Down

0 comments on commit 5931d7e

Please sign in to comment.