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 +4 -4
- data/CHANGELOG.md +10 -0
- data/lib/spreedly/connection.rb +0 -8
- data/lib/spreedly/environment.rb +3 -1
- data/lib/spreedly/ssl_requester.rb +0 -4
- data/lib/spreedly/version.rb +1 -1
- data/test/remote/remote_gateway_options_test.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: bd62d311d27a632c63ef13a87a05536a08cce98d9310da15a56663e9c513f64e
|
4
|
+
data.tar.gz: 6912560eb6117a7733f1323038c92d2b04fb3c7bec3bc5764e0d61d114dc2379
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
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`
|
data/lib/spreedly/connection.rb
CHANGED
@@ -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
|
|
data/lib/spreedly/environment.rb
CHANGED
@@ -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
|
|
data/lib/spreedly/version.rb
CHANGED
@@ -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
|
-
|
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.
|
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-
|
11
|
+
date: 2023-08-25 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: nokogiri
|