solidus_paypal_commerce_platform 1.0.1 → 1.0.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 951c4cf66ca9906f99a1f843cc4999ec34f079b0e1192f8d70025e43991b2413
4
- data.tar.gz: 8cb0703b32727cf0b48e9ae2910c53148a2428a6ecf825ab45e66e0709e9ae6d
3
+ metadata.gz: dfb7ee341074d3d81cfc59a715ef14aeb98cae039965ee08fcdd398bc09a223b
4
+ data.tar.gz: '0491f84853194b9b601a19b22242604bb5c92c2b692e5f85ee61b704c4623fad'
5
5
  SHA512:
6
- metadata.gz: d25ebd6b9b2160a705dc0808d0120eec6aeefe8bb4343247645f06d7ab3d570eb55b292f6a9e723c5e85046770de18b01a731a1f910e360827751d5938d61676
7
- data.tar.gz: 884f6e51fa0ac3348c71b25d22c0e2935d5dafbf97f8860124dce590d525ece4fe5b301c96db7e532e3098d42114efffe8a010ae1d0b0ecfb7ed0270bd698bf1
6
+ metadata.gz: 945f8991754ec669587007c1cd0349d012fa27e0c7ac30e87d3a239555c1f70b6a701df67b099d182f9a5fd291c8520df2fe61bc4d987f99d023d0f70ab7a092
7
+ data.tar.gz: cbff4cf00b1dfa87c052cb6e6e30b77af87e27cab7866fccb515ca37e33f7034bba609182516c83f50eb28645b779a6609aa0b3e411229401f8a706d30875316
data/.circleci/config.yml CHANGED
@@ -20,7 +20,7 @@ commands:
20
20
  sudo apt-get update
21
21
  sudo apt-get install -yq libvips-dev
22
22
  - solidusio_extensions/test-branch:
23
- branch: master
23
+ branch: main
24
24
  command: |
25
25
  export FRONTEND=starter
26
26
  sudo gem update --system
@@ -33,26 +33,28 @@ jobs:
33
33
  run-specs-with-postgres:
34
34
  executor:
35
35
  name: solidusio_extensions/postgres
36
- ruby_version: '3.1'
36
+ ruby_version: '3.2'
37
37
  steps:
38
38
  - test-with-starter-frontend
39
39
 
40
40
  run-specs-with-mysql:
41
41
  executor:
42
42
  name: solidusio_extensions/mysql
43
- ruby_version: '3.0'
43
+ ruby_version: '3.1'
44
44
  steps:
45
45
  - test-with-starter-frontend
46
46
 
47
47
  run-specs-with-sqlite:
48
48
  executor:
49
49
  name: solidusio_extensions/sqlite
50
- ruby_version: '2.7'
50
+ ruby_version: '3.0'
51
51
  steps:
52
52
  - test-with-starter-frontend
53
53
 
54
54
  lint-code:
55
- executor: solidusio_extensions/sqlite-memory
55
+ executor:
56
+ name: solidusio_extensions/sqlite-memory
57
+ ruby_version: '3.0'
56
58
  steps:
57
59
  - solidusio_extensions/lint-code
58
60
 
@@ -64,14 +66,14 @@ workflows:
64
66
  - run-specs-with-sqlite
65
67
  - lint-code
66
68
 
67
- "Weekly run specs against master":
69
+ "Weekly run specs against main":
68
70
  triggers:
69
71
  - schedule:
70
72
  cron: "0 0 * * 4" # every Thursday
71
73
  filters:
72
74
  branches:
73
75
  only:
74
- - master
76
+ - main
75
77
  jobs:
76
78
  - run-specs-with-postgres
77
79
  - run-specs-with-mysql
data/.rubocop.yml CHANGED
@@ -3,7 +3,7 @@ require:
3
3
 
4
4
  AllCops:
5
5
  NewCops: disable
6
- TargetRubyVersion: '2.7'
6
+ TargetRubyVersion: '3.0'
7
7
  Exclude:
8
8
  - sandbox/**/*
9
9
  - dummy-app/**/*
@@ -69,3 +69,6 @@ Rails/Inquiry:
69
69
  Enabled: true
70
70
  Exclude:
71
71
  - spec/lib/solidus_paypal_commerce_platform/configuration_spec.rb
72
+
73
+ Layout/LineLength:
74
+ Enabled: false
data/README.md CHANGED
@@ -1,7 +1,7 @@
1
1
  # Solidus Paypal Commerce Platform
2
2
 
3
3
  [![CircleCI](https://circleci.com/gh/solidusio/solidus_paypal_commerce_platform.svg?style=shield)](https://circleci.com/gh/solidusio/solidus_paypal_commerce_platform)
4
- [![codecov](https://codecov.io/gh/solidusio-contrib/solidus_paypal_commerce_platform/branch/master/graph/badge.svg?token=J8HCLE0CZW)](https://codecov.io/gh/solidusio-contrib/solidus_paypal_commerce_platform)
4
+ [![codecov](https://codecov.io/gh/solidusio-contrib/solidus_paypal_commerce_platform/branch/main/graph/badge.svg?token=J8HCLE0CZW)](https://codecov.io/gh/solidusio-contrib/solidus_paypal_commerce_platform)
5
5
 
6
6
  The official PayPal integration of Solidus.
7
7
 
@@ -6,7 +6,7 @@ module SolidusPaypalCommercePlatform
6
6
  include PayPalCheckoutSdk::Payments
7
7
 
8
8
  def initialize(options)
9
- # Cannot use kwargs because of how the Gateway is initialize by Solidus.
9
+ # Cannot use kwargs because of how the Gateway is initialized by Solidus.
10
10
  @client = Client.new(
11
11
  test_mode: options.fetch(:test_mode, nil),
12
12
  client_id: options.fetch(:client_id),
data/bin/dummy-app CHANGED
@@ -28,7 +28,7 @@ if [ ! -d "dummy-app" ]; then
28
28
  fi
29
29
 
30
30
  cd ./dummy-app
31
- unbundled bundle add solidus --github solidusio/solidus --branch "${BRANCH:-master}" --version '> 0.a'
31
+ unbundled bundle add solidus --github solidusio/solidus --branch "${BRANCH:-main}" --version '> 0.a'
32
32
  unbundled bundle exec rake db:drop db:create
33
33
  unbundled bundle exec rails generate solidus:install --auto-accept --payment-method=none --no-seed --no-sample "$@"
34
34
  unbundled bundle add $extension_name --path ..
data/bin/sandbox CHANGED
@@ -22,7 +22,7 @@ if [ ! -z $SOLIDUS_BRANCH ]
22
22
  then
23
23
  BRANCH=$SOLIDUS_BRANCH
24
24
  else
25
- BRANCH="master"
25
+ BRANCH="main"
26
26
  fi
27
27
 
28
28
  extension_name="solidus_paypal_commerce_platform"
@@ -47,7 +47,7 @@ if [ ! -d "sandbox" ]; then
47
47
  fi
48
48
 
49
49
  cd ./sandbox
50
- unbundled bundle add solidus --github solidusio/solidus --branch "${BRANCH:-master}" --version '> 0.a'
50
+ unbundled bundle add solidus --github solidusio/solidus --branch "${BRANCH:-main}" --version '> 0.a'
51
51
  unbundled bundle exec rake db:drop db:create
52
52
  unbundled bundle exec rails generate solidus:install --payment-method=none --auto-accept "$@"
53
53
  unbundled bundle add ${extension_name} --path '../'
@@ -25,7 +25,7 @@ module SolidusPaypalCommercePlatform
25
25
  directory 'config/initializers', 'config/initializers'
26
26
  rake 'railties:install:migrations FROM=solidus_paypal_commerce_platform'
27
27
  run 'bin/rails db:migrate' if options[:migrate]
28
- route "mount SolidusPaypalCommercePlatform::Engine, at: '/solidus_paypal_commerce_platform'"
28
+ route "mount SolidusPaypalCommercePlatform::Engine, at: '#{solidus_mount_point}solidus_paypal_commerce_platform'"
29
29
  end
30
30
 
31
31
  def install_solidus_backend_support
@@ -91,6 +91,12 @@ module SolidusPaypalCommercePlatform
91
91
 
92
92
  private
93
93
 
94
+ def solidus_mount_point
95
+ mount_point = ::Spree::Core::Engine.routes.find_script_name({})
96
+ mount_point += "/" unless mount_point.end_with?("/")
97
+ mount_point
98
+ end
99
+
94
100
  def support_code_for(component_name, &block)
95
101
  if @components[component_name]
96
102
  say_status :install, "[#{engine.engine_name}] solidus_#{component_name}", :blue
@@ -14,6 +14,10 @@ module SolidusPaypalCommercePlatform
14
14
 
15
15
  engine_name 'solidus_paypal_commerce_platform'
16
16
 
17
+ initializer "solidus_paypal_commerce_platform.zeitwerk_ignore_deface_overrides", before: :eager_load! do |app|
18
+ app.autoloaders.main.ignore(root.join('app/overrides'))
19
+ end
20
+
17
21
  initializer "solidus_paypal_commerce_platform.add_payment_method", after: "spree.register.payment_methods" do |app|
18
22
  app.config.to_prepare do
19
23
  app.config.spree.payment_methods << SolidusPaypalCommercePlatform::PaymentMethod
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module SolidusPaypalCommercePlatform
4
- VERSION = '1.0.1'
4
+ VERSION = '1.0.3'
5
5
  end
@@ -17,7 +17,7 @@ Gem::Specification.new do |spec|
17
17
  spec.metadata['changelog_uri'] = 'https://github.com/solidusio/solidus_paypal_commerce_platform/releases'
18
18
  spec.metadata['rubygems_mfa_required'] = 'true'
19
19
 
20
- spec.required_ruby_version = Gem::Requirement.new('>= 2.7')
20
+ spec.required_ruby_version = Gem::Requirement.new('>= 3.0')
21
21
 
22
22
  # Specify which files should be added to the gem when it is released.
23
23
  # The `git ls-files -z` loads the files in the RubyGem that have been added into git.
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- require 'solidus_starter_frontend_helper'
3
+ require 'solidus_starter_frontend_spec_helper'
4
4
 
5
5
  Dir["#{__dir__}/support/solidus_paypal_commerce_platform/**/*.rb"].sort.each { |f| require f }
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: solidus_paypal_commerce_platform
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.1
4
+ version: 1.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sean Denny
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: exe
11
11
  cert_chain: []
12
- date: 2023-04-21 00:00:00.000000000 Z
12
+ date: 2023-12-22 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: deface
@@ -273,14 +273,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
273
273
  requirements:
274
274
  - - ">="
275
275
  - !ruby/object:Gem::Version
276
- version: '2.7'
276
+ version: '3.0'
277
277
  required_rubygems_version: !ruby/object:Gem::Requirement
278
278
  requirements:
279
279
  - - ">="
280
280
  - !ruby/object:Gem::Version
281
281
  version: '0'
282
282
  requirements: []
283
- rubygems_version: 3.3.7
283
+ rubygems_version: 3.4.10
284
284
  signing_key:
285
285
  specification_version: 4
286
286
  summary: Integrate Solidus with Paypal Commerce Platform