iron_bank 1.0.4 → 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
- SHA256:
3
- metadata.gz: 06a7722694817af7e5d22e0865de23d0f9848a728309d6643756fa7645f387c9
4
- data.tar.gz: 8ca2222d3c3a9b94446e473ee1000fd8ac2f50bf8129b1a6add3c137705ad874
2
+ SHA1:
3
+ metadata.gz: 7b44c23ef147468febcaa424fc386905e956383b
4
+ data.tar.gz: c75b2d1b28b9b46ade61e3b3a2500c9908fefab3
5
5
  SHA512:
6
- metadata.gz: da4c04ba2325489d70440a8a3b3c892d637f6baf12a923cebe054401b8a377a9dc245ab79fefb82a512de3ab2b01bde9522d3b4fbccbe538168643e924fbb647
7
- data.tar.gz: 51e9c6767acd5aad9a0ec05190a8f5c3fdba8011ebefece40311d14edaa83d5181ae8a8de6d162b72665bdc360b3fc2b69dbf109ff0657bafb54c9634eeee88f
6
+ metadata.gz: a79828f6152c630e86f4e56b25d95cb533d4e66ce348ac623c486c962944165b8d0b0d388beea9a116b04997a02d0b4692c7ce7ac7c9c36b5be82abcb3eaab41
7
+ data.tar.gz: d323fbda75c7d13afe62b8a2f02ef363bd7268cea1427b5016442fb077e08de23feb27366d6dab0b11a7f4a12f7039b2333e8958d7823dd250b868319ba6033b
data/.reek.yml ADDED
@@ -0,0 +1,101 @@
1
+ ---
2
+
3
+ # Exclude vendor/bundle directory for Travis
4
+ exclude_paths:
5
+ - vendor/bundle
6
+
7
+ detectors:
8
+ Attribute:
9
+ exclude:
10
+ - IronBank#client
11
+ - IronBank#configuration
12
+ - IronBank::Configuration#auth_type
13
+ - IronBank::Configuration#cache
14
+ - IronBank::Configuration#client_id
15
+ - IronBank::Configuration#client_secret
16
+ - IronBank::Configuration#domain
17
+ - IronBank::Configuration#export_directory
18
+ - IronBank::Configuration#instrumenter
19
+ - IronBank::Configuration#instrumenter_options
20
+ - IronBank::Configuration#logger
21
+ - IronBank::Configuration#open_tracing_enabled
22
+ - IronBank::Configuration#open_tracing_service_name
23
+ - IronBank::Configuration#schema_directory
24
+
25
+ BooleanParameter:
26
+ exclude:
27
+ - IronBank::Cacheable::ClassMethods#find
28
+
29
+ DuplicateMethodCall:
30
+ exclude:
31
+ - IronBank::Utils#camelize
32
+ - IronBank::Local#all
33
+
34
+ FeatureEnvy:
35
+ exclude:
36
+ - IronBank::Client#connection
37
+ - IronBank::Authentications::Cookie#connection
38
+ - IronBank::Authentications::Token#connection
39
+ - IronBank::Configuration#schema_directory=
40
+ - IronBank::Resource#==
41
+ - IronBank::Object#camelize
42
+ - IronBank::Object#underscore
43
+ - IronBank::Actions::Subscribe#hash_args
44
+ - IronBank::Utils#camelize
45
+
46
+ InstanceVariableAssumption:
47
+ exclude:
48
+ - IronBank::FaradayMiddleware::RetriableAuth
49
+
50
+ IrresponsibleModule:
51
+ exclude:
52
+ - Sample
53
+
54
+ ManualDispatch:
55
+ exclude:
56
+ - IronBank::Resource#inspect
57
+
58
+ NestedIterators:
59
+ exclude:
60
+ - IronBank::Schema#self.import
61
+ - IronBank::Local#where
62
+ - IronBank::Local#load_records
63
+ - IronBank::Resources::ProductRatePlanChargeTier#self.load_records
64
+
65
+ NilCheck:
66
+ exclude:
67
+ - IronBank::Local#load_records
68
+ - IronBank::Resources::ProductRatePlanChargeTier#self.load_records
69
+
70
+ TooManyInstanceVariables:
71
+ max_instance_variables: 6
72
+
73
+ TooManyStatements:
74
+ exclude:
75
+ - IronBank::Associations::ClassMethods#with_many
76
+ - IronBank::Associations::ClassMethods#with_one
77
+ - IronBank::Authentications::Cookie#connection
78
+ - IronBank::Authentications::Token#connection
79
+ - IronBank::Client#connection
80
+ - IronBank::Configuration#schema_directory=
81
+ - IronBank::Configuration#initialize
82
+ - IronBank::Queryable#find_each
83
+ - IronBank::Queryable#where
84
+ - IronBank::Utils#camelize
85
+ - IronBank::Utils#underscore
86
+ - IronBank::Resources::ProductRatePlanChargeTier#self.load_records
87
+ - IronBank::Error#self.from_response
88
+
89
+ UtilityFunction:
90
+ exclude:
91
+ - IronBank::Cacheable::ClassMethods#cache
92
+ - IronBank::Object#convert
93
+ - IronBank::Object#camelize_array
94
+ - IronBank::Object#underscore_array
95
+ - IronBank::OpenTracing#open_tracing_enabled?
96
+ - IronBank::OpenTracing#open_tracing_options
97
+ - IronBank::QueryBuilder#range_query_builder
98
+ - IronBank::Utils#lower_camelize
99
+ - IronBank::Utils#upper_camelize
100
+ - IronBank::Instrumentation#instrumenter
101
+ - IronBank::Instrumentation#instrumenter_options
data/.rubocop.yml CHANGED
@@ -6,6 +6,10 @@ AllCops:
6
6
  Layout/DotPosition:
7
7
  EnforcedStyle: trailing
8
8
 
9
+ Layout/AlignHash:
10
+ EnforcedHashRocketStyle: table
11
+ EnforcedColonStyle: table
12
+
9
13
  Lint/UselessAssignment:
10
14
  Exclude:
11
15
  - bin/console
data/.travis.yml CHANGED
@@ -3,10 +3,9 @@ cache: bundler
3
3
  language: ruby
4
4
 
5
5
  rvm:
6
- - 2.2.9
7
- - 2.3.5
8
- - 2.4.4
9
- - 2.5.1
6
+ - 2.3.8
7
+ - 2.4.5
8
+ - 2.5.3
10
9
 
11
10
  sudo: false
12
11
 
data/README.md CHANGED
@@ -13,7 +13,7 @@ This gem provides opinionated resources to interact with the Zuora API through
13
13
  their REST interface. It defines **associations** between them, as well as a
14
14
  simple **declaration API** (`with_one`, `with_many`) to extend them.
15
15
 
16
- This gem is tested against Ruby `>= 2.2.9`.
16
+ This gem is tested against Ruby `>= 2.3.8`.
17
17
 
18
18
  Please use [GitHub Issues][issues] to report bugs.
19
19
 
data/iron_bank.gemspec CHANGED
@@ -19,6 +19,8 @@ Gem::Specification.new do |spec|
19
19
  'mturan@zendesk.com'
20
20
  ]
21
21
 
22
+ spec.required_ruby_version = '>= 2.3'
23
+
22
24
  spec.files = `git ls-files -z`.split("\x0").reject do |f|
23
25
  f.match(%r{^(test|spec|features)/})
24
26
  end
@@ -33,7 +35,7 @@ Gem::Specification.new do |spec|
33
35
  spec.add_development_dependency 'factory_bot', '~> 4.10'
34
36
  spec.add_development_dependency 'pry-byebug', '~> 3.4'
35
37
  spec.add_development_dependency 'rake', '~> 12.0'
36
- spec.add_development_dependency 'reek', '~> 4.6'
38
+ spec.add_development_dependency 'reek', '~> 5.0'
37
39
  spec.add_development_dependency 'rspec', '~> 3.0'
38
40
  spec.add_development_dependency 'rubocop', '~> 0.52'
39
41
  spec.add_development_dependency 'shoulda-matchers', '~> 3.1'
@@ -12,9 +12,10 @@ module IronBank
12
12
 
13
13
  def call
14
14
  @body = IronBank.client.connection.post(endpoint, params).body
15
- return body if success?
16
15
 
17
- raise ::IronBank::UnprocessableEntity, errors
16
+ raise ::IronBank::UnprocessableEntity, errors unless success?
17
+
18
+ IronBank::Object.new(body).deep_underscore
18
19
  end
19
20
 
20
21
  private
@@ -48,11 +49,5 @@ module IronBank
48
49
  def errors
49
50
  { errors: response_object.fetch(:errors, []) }
50
51
  end
51
-
52
- def requests(type: :upper)
53
- args.fetch(:objects).map do |object|
54
- IronBank::Object.new(object).deep_camelize(type: type)
55
- end
56
- end
57
52
  end
58
53
  end
@@ -6,10 +6,20 @@ module IronBank
6
6
  # https://www.zuora.com/developer/api-reference/#operation/Action_POSTamend
7
7
  #
8
8
  class Amend < Action
9
+ def call
10
+ # NOTE: The amend response wraps all results in an object, which is
11
+ # inconsistent with the rest of the `/v1/action` responses.
12
+ super[:results]
13
+ end
14
+
9
15
  private
10
16
 
11
17
  def params
12
- { requests: args }
18
+ { requests: requests }
19
+ end
20
+
21
+ def requests
22
+ IronBank::Object.new(args.fetch(:requests)).deep_camelize(type: :upper)
13
23
  end
14
24
  end
15
25
  end
@@ -10,10 +10,18 @@ module IronBank
10
10
 
11
11
  def params
12
12
  {
13
- objects: requests,
14
- type: args.fetch(:type)
13
+ objects: objects,
14
+ type: type
15
15
  }
16
16
  end
17
+
18
+ def objects
19
+ IronBank::Object.new(args.fetch(:objects)).deep_camelize(type: :upper)
20
+ end
21
+
22
+ def type
23
+ IronBank::Utils.camelize(args.fetch(:type), type: :upper)
24
+ end
17
25
  end
18
26
  end
19
27
  end
@@ -11,9 +11,13 @@ module IronBank
11
11
  def params
12
12
  {
13
13
  ids: args.fetch(:ids),
14
- type: args.fetch(:type)
14
+ type: type
15
15
  }
16
16
  end
17
+
18
+ def type
19
+ IronBank::Utils.camelize(args.fetch(:type), type: :upper)
20
+ end
17
21
  end
18
22
  end
19
23
  end
@@ -13,9 +13,13 @@ module IronBank
13
13
  {
14
14
  ids: args.fetch(:ids),
15
15
  synchronous: args.fetch(:synchronous),
16
- type: args.fetch(:type)
16
+ type: type
17
17
  }
18
18
  end
19
+
20
+ def type
21
+ IronBank::Utils.camelize(args.fetch(:type), type: :upper)
22
+ end
19
23
  end
20
24
  end
21
25
  end
@@ -10,10 +10,18 @@ module IronBank
10
10
 
11
11
  def params
12
12
  {
13
- objects: args.fetch(:objects).map(&:deep_camelize),
14
- type: args.fetch(:type)
13
+ objects: objects,
14
+ type: type
15
15
  }
16
16
  end
17
+
18
+ def objects
19
+ IronBank::Object.new(args.fetch(:objects)).deep_camelize(type: :upper)
20
+ end
21
+
22
+ def type
23
+ IronBank::Utils.camelize(args.fetch(:type), type: :upper)
24
+ end
17
25
  end
18
26
  end
19
27
  end
@@ -9,7 +9,7 @@ module IronBank
9
9
  private
10
10
 
11
11
  def params
12
- { 'queryString' => args }
12
+ { 'queryString': args }
13
13
  end
14
14
  end
15
15
  end
@@ -9,7 +9,7 @@ module IronBank
9
9
  private
10
10
 
11
11
  def params
12
- { 'queryLocator' => args }
12
+ { 'queryLocator': args }
13
13
  end
14
14
 
15
15
  # NOTE: Zuora API endpoint is case-sensitive.
@@ -7,25 +7,14 @@ module IronBank
7
7
  # https://www.zuora.com/developer/api-reference/#operation/Action_POSTsubscribe
8
8
  #
9
9
  class Subscribe < Action
10
- def call
11
- body = IronBank.client.connection.post(endpoint, params).body
12
-
13
- if body.is_a?(Array)
14
- body.map { |result| IronBank::Object.new(result).deep_underscore }
15
- else
16
- IronBank::Object.new(body).deep_underscore
17
- end
18
- end
19
-
20
10
  private
21
11
 
22
12
  def params
23
- { subscribes: subscribe_requests }
13
+ { subscribes: subscribes }
24
14
  end
25
15
 
26
- def subscribe_requests
27
- requests = [args].flatten
28
- requests.map { |request| IronBank::Object.new(request).deep_camelize }
16
+ def subscribes
17
+ IronBank::Object.new(args.fetch(:subscribes)).deep_camelize
29
18
  end
30
19
  end
31
20
  end
@@ -10,10 +10,18 @@ module IronBank
10
10
 
11
11
  def params
12
12
  {
13
- objects: requests,
14
- type: args.fetch(:type)
13
+ objects: objects,
14
+ type: type
15
15
  }
16
16
  end
17
+
18
+ def objects
19
+ IronBank::Object.new(args.fetch(:objects)).deep_camelize(type: :upper)
20
+ end
21
+
22
+ def type
23
+ IronBank::Utils.camelize(args.fetch(:type), type: :upper)
24
+ end
17
25
  end
18
26
  end
19
27
  end
@@ -25,9 +25,8 @@ module IronBank
25
25
  end
26
26
  end
27
27
 
28
- # Association is "also known as"
29
- aka = options[:aka]
30
- alias_method aka, name if aka
28
+ alias_name = options[:alias]
29
+ alias_method alias_name, name if alias_name
31
30
  end
32
31
 
33
32
  def with_many(name, options = {})
@@ -53,9 +52,8 @@ module IronBank
53
52
  end
54
53
  end
55
54
 
56
- # Association is "also known as"
57
- aka = options[:aka]
58
- alias_method aka, name if aka
55
+ alias_name = options[:alias]
56
+ alias_method alias_name, name if alias_name
59
57
  end
60
58
  end
61
59
 
@@ -6,9 +6,9 @@ module IronBank
6
6
  class Endpoint
7
7
  private_class_method :new
8
8
 
9
- PRODUCTION = /\Arest\.zuora\.com\z/i
10
- SERVICES = /\Aservices(\d+)\.zuora\.com(:\d+)?\z/i
11
- APISANDBOX = /\Arest.apisandbox.zuora\.com\z/i
9
+ PRODUCTION = /\Arest\.zuora\.com\z/i.freeze
10
+ SERVICES = /\Aservices(\d+)\.zuora\.com(:\d+)?\z/i.freeze
11
+ APISANDBOX = /\Arest.apisandbox.zuora\.com\z/i.freeze
12
12
 
13
13
  def self.base_url(domain = '')
14
14
  new(domain).base_url
@@ -1,15 +1,27 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module IronBank
4
- # This object holds the initial payload (hash) sent through one of the
5
- # action/operation. It exposes methods to convert the payload to either
6
- # upper camel case (typically used by actions) or lower camel case.
4
+ # This object holds the initial payload sent to an action/operation. It
5
+ # exposes methods to convert the payload keys to either upper camel case
6
+ # (typically used by actions) or lower camel case.
7
7
  #
8
8
  # It is also use to parse the response from Zuora and convert it into a Ruby-
9
9
  # friendly Hash.
10
10
  #
11
11
  class Object
12
- SNOWFLAKE_FIELDS = ['fieldsToNull'].freeze
12
+ UNMODIFIED_FIELD_KEYS = %w[
13
+ fieldsToNull
14
+ ].freeze
15
+
16
+ CAMELIZER = lambda do |type, key|
17
+ return key if UNMODIFIED_FIELD_KEYS.include?(key.to_s)
18
+
19
+ IronBank::Utils.camelize(key, type: type)
20
+ end
21
+
22
+ UNDERSCORER = lambda do |key|
23
+ IronBank::Utils.underscore(key).to_sym
24
+ end
13
25
 
14
26
  attr_reader :payload
15
27
 
@@ -17,72 +29,40 @@ module IronBank
17
29
  @payload = payload
18
30
  end
19
31
 
20
- # FIXME: refactor both camelize/underscore methods into one
21
32
  def deep_camelize(type: :upper)
22
- payload.each_pair.with_object({}) do |(field, value), hash|
23
- field = field.to_s
24
-
25
- key = if SNOWFLAKE_FIELDS.include?(field)
26
- field
27
- else
28
- IronBank::Utils.camelize(field, type: type)
29
- end
33
+ @prok = CAMELIZER.curry[type]
30
34
 
31
- hash[key] = camelize(value, type: type)
32
- end
35
+ transform(payload)
33
36
  end
34
37
 
35
- # FIXME: refactor both camelize/underscore methods into one
36
38
  def deep_underscore
37
- payload.each_pair.with_object({}) do |(field, value), hash|
38
- key = IronBank::Utils.underscore(field.to_s).to_sym
39
- hash[key] = underscore(value)
40
- end
39
+ @prok = UNDERSCORER
40
+
41
+ transform(payload)
41
42
  end
42
43
 
43
44
  private
44
45
 
45
- # FIXME: refactor both camelize/underscore methods into one
46
- def camelize(value, type: :upper)
47
- if value.is_a?(Array)
48
- camelize_array(value, type: type)
49
- elsif value.is_a?(Hash)
50
- IronBank::Object.new(value).deep_camelize(type: type)
51
- elsif value.is_a?(IronBank::Object)
52
- value.deep_camelize(type: type)
53
- else
54
- value
55
- end
56
- end
46
+ attr_reader :prok
57
47
 
58
- # FIXME: refactor both camelize/underscore methods into one
59
- def camelize_array(value, type: :upper)
60
- value.each.with_object([]) do |item, payload|
61
- item = IronBank::Object.new(item) if item.is_a?(Hash)
62
- item = item.deep_camelize(type: type) unless item.is_a?(String)
63
-
64
- payload.push(item)
48
+ def transform(value)
49
+ case value
50
+ when Array then transform_array(value)
51
+ when Hash then transform_hash(value)
52
+ when IronBank::Object then transform(value.payload)
53
+ else value
65
54
  end
66
55
  end
67
56
 
68
- # FIXME: refactor both camelize/underscore methods into one
69
- def underscore(value)
70
- if value.is_a?(Array)
71
- underscore_array(value)
72
- elsif value.is_a?(Hash)
73
- IronBank::Object.new(value).deep_underscore
74
- elsif value.is_a?(IronBank::Object)
75
- value.deep_underscore
76
- else
77
- value
78
- end
57
+ def transform_array(array)
58
+ array.map { |element| transform(element) }
79
59
  end
80
60
 
81
- # FIXME: refactor both camelize/underscore methods into one
82
- def underscore_array(value)
83
- value.each.with_object([]) do |item, payload|
84
- item = IronBank::Object.new(item) if item.is_a?(Hash)
85
- payload.push(item.deep_underscore)
61
+ def transform_hash(hash)
62
+ hash.each.with_object({}) do |(key, value), hsh|
63
+ key = prok.call(key.to_s)
64
+
65
+ hsh[key] = transform(value)
86
66
  end
87
67
  end
88
68
  end
@@ -32,7 +32,7 @@ module IronBank
32
32
  with_many :subscriptions
33
33
  with_many :active_subscriptions,
34
34
  resource_name: 'Subscription',
35
- conditions: { status: 'Active' }
35
+ conditions: { status: 'Active' }
36
36
 
37
37
  # Invoices
38
38
  with_many :invoices
@@ -23,8 +23,8 @@ module IronBank
23
23
 
24
24
  with_one :account
25
25
 
26
- with_many :invoice_adjustments, aka: :adjustments
27
- with_many :invoice_items, aka: :items
26
+ with_many :invoice_adjustments, alias: :adjustments
27
+ with_many :invoice_items, alias: :items
28
28
  with_many :invoice_payments
29
29
 
30
30
  # We can only retrieve one invoice body at a time, hence Body is excluded
@@ -8,7 +8,7 @@ module IronBank
8
8
  with_schema
9
9
  with_local_records
10
10
  with_cache
11
- with_many :product_rate_plans, aka: :plans
11
+ with_many :product_rate_plans, alias: :plans
12
12
  end
13
13
  end
14
14
  end
@@ -16,7 +16,7 @@ module IronBank
16
16
  with_cache
17
17
 
18
18
  with_one :product
19
- with_many :product_rate_plan_charges, aka: :charges
19
+ with_many :product_rate_plan_charges, alias: :charges
20
20
 
21
21
  def active_currencies
22
22
  query_string = IronBank::QueryBuilder.zoql(
@@ -19,9 +19,9 @@ module IronBank
19
19
  with_local_records
20
20
  with_cache
21
21
 
22
- with_one :product_rate_plan, aka: :plan
22
+ with_one :product_rate_plan, alias: :plan
23
23
 
24
- with_many :product_rate_plan_charge_tiers, aka: :tiers
24
+ with_many :product_rate_plan_charge_tiers, alias: :tiers
25
25
  end
26
26
  end
27
27
  end
@@ -10,7 +10,7 @@ module IronBank
10
10
  with_local_records
11
11
  with_cache
12
12
 
13
- with_one :product_rate_plan_charge, aka: :charge
13
+ with_one :product_rate_plan_charge, alias: :charge
14
14
 
15
15
  def self.where(conditions)
16
16
  # If we are coming from a subclass, defer to Queryable#all
@@ -10,11 +10,11 @@ module IronBank
10
10
  with_cache
11
11
 
12
12
  with_one :amendment
13
- with_one :product_rate_plan, aka: :catalog_plan
13
+ with_one :product_rate_plan, alias: :catalog_plan
14
14
  with_one :subscription
15
15
 
16
16
  with_many :rate_plan_charges,
17
- aka: :charges,
17
+ alias: :charges,
18
18
  conditions: { is_last_segment: true }
19
19
  end
20
20
  end
@@ -21,10 +21,10 @@ module IronBank
21
21
  with_cache
22
22
 
23
23
  with_one :original, resource_name: 'RatePlanCharge'
24
- with_one :product_rate_plan_charge, aka: :catalog_charge
25
- with_one :rate_plan, aka: :plan
24
+ with_one :product_rate_plan_charge, alias: :catalog_charge
25
+ with_one :rate_plan, alias: :plan
26
26
 
27
- with_many :rate_plan_charge_tiers, aka: :tiers
27
+ with_many :rate_plan_charge_tiers, alias: :tiers
28
28
  end
29
29
  end
30
30
  end
@@ -20,7 +20,7 @@ module IronBank
20
20
  with_schema
21
21
  with_cache
22
22
 
23
- with_one :rate_plan_charge, aka: :charge
23
+ with_one :rate_plan_charge, alias: :charge
24
24
  end
25
25
  end
26
26
  end
@@ -15,9 +15,9 @@ module IronBank
15
15
  with_one :original, resource_name: 'Subscription'
16
16
  with_one :previous,
17
17
  resource_name: 'Subscription',
18
- foreign_key: 'previous_subscription_id'
18
+ foreign_key: 'previous_subscription_id'
19
19
 
20
- with_many :rate_plans, aka: :plans
20
+ with_many :rate_plans, alias: :plans
21
21
  with_many :usages
22
22
 
23
23
  # FIXME: a subscription can only have at most one amendment (no amendment
@@ -1,6 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module IronBank
4
- VERSION = '1.0.4'
4
+ VERSION = '2.0.0'
5
5
  API_VERSION = 'v1'
6
6
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: iron_bank
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.4
4
+ version: 2.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mickael Pham
@@ -11,7 +11,7 @@ authors:
11
11
  autorequire:
12
12
  bindir: exe
13
13
  cert_chain: []
14
- date: 2018-10-12 00:00:00.000000000 Z
14
+ date: 2018-12-08 00:00:00.000000000 Z
15
15
  dependencies:
16
16
  - !ruby/object:Gem::Dependency
17
17
  name: bump
@@ -103,14 +103,14 @@ dependencies:
103
103
  requirements:
104
104
  - - "~>"
105
105
  - !ruby/object:Gem::Version
106
- version: '4.6'
106
+ version: '5.0'
107
107
  type: :development
108
108
  prerelease: false
109
109
  version_requirements: !ruby/object:Gem::Requirement
110
110
  requirements:
111
111
  - - "~>"
112
112
  - !ruby/object:Gem::Version
113
- version: '4.6'
113
+ version: '5.0'
114
114
  - !ruby/object:Gem::Dependency
115
115
  name: rspec
116
116
  requirement: !ruby/object:Gem::Requirement
@@ -279,7 +279,7 @@ files:
279
279
  - ".github/CODEOWNERS"
280
280
  - ".github/PULL_REQUEST_TEMPLATE.md"
281
281
  - ".gitignore"
282
- - ".reek"
282
+ - ".reek.yml"
283
283
  - ".rspec"
284
284
  - ".rubocop.yml"
285
285
  - ".travis.yml"
@@ -372,7 +372,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
372
372
  requirements:
373
373
  - - ">="
374
374
  - !ruby/object:Gem::Version
375
- version: '0'
375
+ version: '2.3'
376
376
  required_rubygems_version: !ruby/object:Gem::Requirement
377
377
  requirements:
378
378
  - - ">="
@@ -380,7 +380,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
380
380
  version: '0'
381
381
  requirements: []
382
382
  rubyforge_project:
383
- rubygems_version: 2.7.7
383
+ rubygems_version: 2.5.2.3
384
384
  signing_key:
385
385
  specification_version: 4
386
386
  summary: An opinionated Ruby interface to the Zuora API.
data/.reek DELETED
@@ -1,100 +0,0 @@
1
- ---
2
-
3
- # Exclude vendor/bundle directory for Travis
4
- exclude_paths:
5
- - vendor/bundle
6
-
7
- Attribute:
8
- exclude:
9
- - IronBank#client
10
- - IronBank#configuration
11
- - IronBank::Configuration#auth_type
12
- - IronBank::Configuration#cache
13
- - IronBank::Configuration#client_id
14
- - IronBank::Configuration#client_secret
15
- - IronBank::Configuration#domain
16
- - IronBank::Configuration#export_directory
17
- - IronBank::Configuration#instrumenter
18
- - IronBank::Configuration#instrumenter_options
19
- - IronBank::Configuration#logger
20
- - IronBank::Configuration#open_tracing_enabled
21
- - IronBank::Configuration#open_tracing_service_name
22
- - IronBank::Configuration#schema_directory
23
-
24
- BooleanParameter:
25
- exclude:
26
- - IronBank::Cacheable::ClassMethods#find
27
-
28
- DuplicateMethodCall:
29
- exclude:
30
- - IronBank::Utils#camelize
31
- - IronBank::Local#all
32
-
33
- FeatureEnvy:
34
- exclude:
35
- - IronBank::Client#connection
36
- - IronBank::Authentications::Cookie#connection
37
- - IronBank::Authentications::Token#connection
38
- - IronBank::Configuration#schema_directory=
39
- - IronBank::Resource#==
40
- - IronBank::Object#camelize
41
- - IronBank::Object#underscore
42
- - IronBank::Actions::Subscribe#hash_args
43
- - IronBank::Utils#camelize
44
-
45
- InstanceVariableAssumption:
46
- exclude:
47
- - IronBank::FaradayMiddleware::RetriableAuth
48
-
49
- IrresponsibleModule:
50
- exclude:
51
- - Sample
52
-
53
- ManualDispatch:
54
- exclude:
55
- - IronBank::Resource#inspect
56
-
57
- NestedIterators:
58
- exclude:
59
- - IronBank::Schema#self.import
60
- - IronBank::Local#where
61
- - IronBank::Local#load_records
62
- - IronBank::Resources::ProductRatePlanChargeTier#self.load_records
63
-
64
- NilCheck:
65
- exclude:
66
- - IronBank::Local#load_records
67
- - IronBank::Resources::ProductRatePlanChargeTier#self.load_records
68
-
69
- TooManyInstanceVariables:
70
- max_instance_variables: 6
71
-
72
- TooManyStatements:
73
- exclude:
74
- - IronBank::Associations::ClassMethods#with_many
75
- - IronBank::Associations::ClassMethods#with_one
76
- - IronBank::Authentications::Cookie#connection
77
- - IronBank::Authentications::Token#connection
78
- - IronBank::Client#connection
79
- - IronBank::Configuration#schema_directory=
80
- - IronBank::Configuration#initialize
81
- - IronBank::Queryable#find_each
82
- - IronBank::Queryable#where
83
- - IronBank::Utils#camelize
84
- - IronBank::Utils#underscore
85
- - IronBank::Resources::ProductRatePlanChargeTier#self.load_records
86
- - IronBank::Error#self.from_response
87
-
88
- UtilityFunction:
89
- exclude:
90
- - IronBank::Cacheable::ClassMethods#cache
91
- - IronBank::Object#convert
92
- - IronBank::Object#camelize_array
93
- - IronBank::Object#underscore_array
94
- - IronBank::OpenTracing#open_tracing_enabled?
95
- - IronBank::OpenTracing#open_tracing_options
96
- - IronBank::QueryBuilder#range_query_builder
97
- - IronBank::Utils#lower_camelize
98
- - IronBank::Utils#upper_camelize
99
- - IronBank::Instrumentation#instrumenter
100
- - IronBank::Instrumentation#instrumenter_options