spreedly 2.0.26 → 2.0.28

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: 4241e7c879a8e9176ed51042a716ba1725874f5d4fa788929775cb09237df89d
4
- data.tar.gz: 84b1c9b35b9574267727e23b1c06e325d8170dcbbc2d761de6fd58e74fbf1a75
3
+ metadata.gz: bd62d311d27a632c63ef13a87a05536a08cce98d9310da15a56663e9c513f64e
4
+ data.tar.gz: 6912560eb6117a7733f1323038c92d2b04fb3c7bec3bc5764e0d61d114dc2379
5
5
  SHA512:
6
- metadata.gz: 75e042c324d777daaf5376ec19fd6f4fd504dead642fe571c9fbf3020a3275687ed1738dea120ff26f8bbfc41762d66227d5f56ef0400206dd0e04c8d9bde844
7
- data.tar.gz: f664bd05e797fa1bbda9db56a089c2f6069e7d39af69b7b5f8c282889876d53d7f1aab18f733020ebd417277f6adde6cc3ba0b9dab0578310bc84e851b99897d
6
+ metadata.gz: aa90bcfc67373de626d8c9eb5e05ea7c6d76598794532c821ce62d42d5cde106c40998179a08ba69c631facc58be445c81fa6e947e333d0b5600e8c0e0e3e567
7
+ data.tar.gz: e9ffff815c1123351d25cec2540ad6e0c1dcc8829c3d94eb559189c26cd40dc56abb812fc1478e30ab300fca6b1a781b2035acb114c734b9f5591894914d701d
data/CHANGELOG.md CHANGED
@@ -1,6 +1,16 @@
1
1
  # Changelog
2
2
 
3
3
  All notable changes to this project will be documented in this file.
4
+
5
+ ## [2.0.28] - 2023-08-23
6
+ ### Changed
7
+ - @jknipp - Merge fix for Spreedly version error in User-Agent header reference from @mrudult
8
+
9
+ ## [2.0.27] - 2023-03-27
10
+ ### Changed
11
+ - @jknipp - Add User-Agent header to requests
12
+ - @jknipp - Remove unused options request logic
13
+
4
14
  ## [2.0.26] - 2023-03-24
5
15
  ### Changed
6
16
  - @jknipp - Update the gateway options url to use `GET /v1/gateways_options.xml` instead of `OPTIONS /v1/gateways.xml`
@@ -20,8 +20,6 @@ module Spreedly
20
20
  http.put(endpoint.request_uri, body, headers)
21
21
  when :delete
22
22
  http.delete(endpoint.request_uri, headers)
23
- when :options
24
- http.request(OptionsWithResponseBody.new(endpoint.request_uri, headers))
25
23
  else
26
24
  raise ArgumentError, "Unsupported request method #{method.to_s.upcase}"
27
25
  end
@@ -45,11 +43,5 @@ module Spreedly
45
43
 
46
44
  end
47
45
 
48
- class OptionsWithResponseBody < Net::HTTPRequest
49
- METHOD = 'OPTIONS'
50
- REQUEST_HAS_BODY = false
51
- RESPONSE_HAS_BODY = true
52
- end
53
-
54
46
  end
55
47
 
@@ -1,5 +1,6 @@
1
1
  require 'base64'
2
2
  require 'nokogiri'
3
+ require 'spreedly/version'
3
4
 
4
5
  module Spreedly
5
6
  class Environment
@@ -166,7 +167,8 @@ module Spreedly
166
167
  def headers
167
168
  {
168
169
  'Authorization' => ('Basic ' + Base64.strict_encode64("#{@key}:#{@access_secret}").chomp),
169
- 'Content-Type' => 'text/xml'
170
+ 'Content-Type' => 'text/xml',
171
+ 'User-Agent' => "spreedly-gem/#{Spreedly::VERSION}"
170
172
  }
171
173
  end
172
174
 
@@ -16,10 +16,6 @@ module Spreedly
16
16
  ssl_request(:put, endpoint, body, headers)
17
17
  end
18
18
 
19
- def ssl_options(endpoint)
20
- ssl_request(:options, endpoint, nil, {})
21
- end
22
-
23
19
  private
24
20
 
25
21
  def ssl_request(method, endpoint, body, headers, options = {})
@@ -1,3 +1,3 @@
1
1
  module Spreedly
2
- VERSION = "2.0.26"
2
+ VERSION = "2.0.28"
3
3
  end
@@ -10,7 +10,7 @@ class RemoteGatewayOptionsTest < Test::Unit::TestCase
10
10
  gateway_classes = @environment.gateway_options
11
11
  braintree = gateway_classes.select { |each| each.name == "Braintree" }.first
12
12
  assert_equal "http://www.braintreepaymentsolutions.com/", braintree.homepage
13
- assert_equal %w(credit_card third_party_token apple_pay android_pay google_pay), braintree.payment_methods
13
+ assert (%w(credit_card third_party_token apple_pay android_pay google_pay) - braintree.payment_methods).empty?
14
14
  assert_equal %w(asia_pacific europe north_america), braintree.regions
15
15
  assert_equal %w(orange blue), braintree.auth_modes.map { |e| e.auth_mode_type }
16
16
  assert_equal %w(login password), braintree.auth_modes.first.credentials.map { |e| e.name }
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: spreedly
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.26
4
+ version: 2.0.28
5
5
  platform: ruby
6
6
  authors:
7
7
  - Spreedly
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-03-28 00:00:00.000000000 Z
11
+ date: 2023-08-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: nokogiri