braintree 4.31.0 → 4.32.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 +4 -4
- data/lib/braintree/error_codes.rb +10 -0
- data/lib/braintree/transaction/apple_pay_details.rb +1 -0
- data/lib/braintree/transaction/credit_card_details.rb +2 -0
- data/lib/braintree/transaction/google_pay_details.rb +1 -0
- data/lib/braintree/transaction_gateway.rb +1 -1
- data/lib/braintree/version.rb +1 -1
- data/spec/integration/braintree/credit_card_verification_spec.rb +7 -0
- data/spec/integration/braintree/payment_method_us_bank_account_spec.rb +0 -3
- data/spec/integration/braintree/transaction_spec.rb +83 -0
- data/spec/integration/braintree/transaction_us_bank_account_spec.rb +0 -1
- data/spec/integration/braintree/us_bank_account_spec.rb +0 -3
- data/spec/unit/braintree/credit_card_verification_spec.rb +17 -0
- data/spec/unit/braintree/transaction/apple_pay_details_spec.rb +9 -0
- data/spec/unit/braintree/transaction/credit_card_details_spec.rb +10 -1
- data/spec/unit/braintree/transaction/google_pay_details_spec.rb +9 -0
- data/spec/unit/braintree/transaction_gateway_spec.rb +1 -1
- data/spec/unit/braintree/transaction_spec.rb +38 -0
- metadata +3 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: b982c20d1a239e4a623a802fb0c0d6ce66a5be501e767c22a33a7b06a3c09a59
|
|
4
|
+
data.tar.gz: 9d515e47f8d7e5908b21f7ed5ccd98b02f2ce712298082fd67cbc3d88d7fd13d
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 1459fb667fdbb3d3f52feb2082394f347dbe0c3347eef68c87cbc31a8c915fcc96ff8623bbd98f8766e2391801423514fa2db4a4c90f511ea9d2c1c3778f9b3d
|
|
7
|
+
data.tar.gz: 36af58c2cc626136cfaa8bc1f28d2acb8fa47e9e747e0e9eb641acabcbf4e0afadf34556e5467928c4e091a66279b505f952a1fb9e5476e19531f0c81b91a59d
|
|
@@ -395,6 +395,7 @@ module Braintree
|
|
|
395
395
|
PaymentMethodNonceUnknown = "91565"
|
|
396
396
|
PaymentMethodTokenCardTypeIsNotAccepted = "91517"
|
|
397
397
|
PaymentMethodTokenIsInvalid = "91518"
|
|
398
|
+
ProcessingMerchantCategoryCodeIsInvalid = "915265"
|
|
398
399
|
ProcessorAuthorizationCodeCannotBeSet = "91519"
|
|
399
400
|
ProcessorAuthorizationCodeIsInvalid = "81520"
|
|
400
401
|
ProcessorDoesNotSupportAuths = "915104"
|
|
@@ -460,6 +461,15 @@ module Braintree
|
|
|
460
461
|
TransactionMustBeInStateAuthorized = "915218"
|
|
461
462
|
TransactionSourceIsInvalid = "915133"
|
|
462
463
|
TransactionTransferDetailsAreMandatory = "97510"
|
|
464
|
+
TransactionTransferDetailsAreNotApplicable = "97511"
|
|
465
|
+
TransactionTransferReceiverAccountReferenceNumberIsNotValid = "97509"
|
|
466
|
+
TransactionTransferReceiverFirstNameIsNotValid = "97507"
|
|
467
|
+
TransactionTransferReceiverLastNameIsNotValid = "97508"
|
|
468
|
+
TransactionTransferReceiverTaxIdIsNotValid = "97506"
|
|
469
|
+
TransactionTransferSenderAccountReferenceNumberIsNotValid = "97505"
|
|
470
|
+
TransactionTransferSenderFirstNameIsNotValid = "97503"
|
|
471
|
+
TransactionTransferSenderLastNameIsNotValid = "97504"
|
|
472
|
+
TransactionTransferSenderTaxIdIsNotValid = "97502"
|
|
463
473
|
TransactionTransferTypeIsInvalid = "97501"
|
|
464
474
|
TypeIsInvalid = "91523"
|
|
465
475
|
TypeIsRequired = "91524"
|
|
@@ -21,6 +21,7 @@ module Braintree
|
|
|
21
21
|
attr_reader :image_url
|
|
22
22
|
attr_reader :issuing_bank
|
|
23
23
|
attr_reader :last_4
|
|
24
|
+
attr_reader :payment_account_reference
|
|
24
25
|
attr_reader :payroll
|
|
25
26
|
attr_reader :prepaid
|
|
26
27
|
attr_reader :prepaid_reloadable
|
|
@@ -55,6 +56,7 @@ module Braintree
|
|
|
55
56
|
:image_url,
|
|
56
57
|
:issuing_bank,
|
|
57
58
|
:last_4,
|
|
59
|
+
:payment_account_reference,
|
|
58
60
|
:payroll,
|
|
59
61
|
:prepaid,
|
|
60
62
|
:prepaid_reloadable,
|
|
@@ -196,7 +196,7 @@ module Braintree
|
|
|
196
196
|
[
|
|
197
197
|
:amount, :billing_address_id, :channel, :currency_iso_code, :customer_id, :device_data,
|
|
198
198
|
:discount_amount, :exchange_rate_quote_id, :foreign_retailer,
|
|
199
|
-
:merchant_account_id, :order_id, :payment_method_nonce, :payment_method_token,
|
|
199
|
+
:merchant_account_id, :order_id, :payment_method_nonce, :payment_method_token, :processing_merchant_category_code,
|
|
200
200
|
:product_sku, :purchase_order_number, :service_fee_amount, :shared_billing_address_id,
|
|
201
201
|
:shared_customer_id, :shared_payment_method_nonce, :shared_payment_method_token,
|
|
202
202
|
:shared_shipping_address_id, :shipping_address_id, :shipping_amount, :shipping_tax_amount,
|
data/lib/braintree/version.rb
CHANGED
|
@@ -257,6 +257,13 @@ describe Braintree::CreditCardVerification, "search" do
|
|
|
257
257
|
Braintree::CreditCardVerification.find("invalid-id")
|
|
258
258
|
end.to raise_error(Braintree::NotFoundError, 'verification with id "invalid-id" not found')
|
|
259
259
|
end
|
|
260
|
+
|
|
261
|
+
it "finds a verification and returns a payment_account_reference if the verification has one" do
|
|
262
|
+
verification = Braintree::CreditCardVerification.find("threedsecuredverification")
|
|
263
|
+
|
|
264
|
+
expect(verification.credit_card).not_to be_nil
|
|
265
|
+
expect(verification.credit_card).to have_key(:payment_account_reference)
|
|
266
|
+
end
|
|
260
267
|
end
|
|
261
268
|
|
|
262
269
|
describe "self.search" do
|
|
@@ -32,7 +32,6 @@ describe Braintree::PaymentMethod do
|
|
|
32
32
|
expect(us_bank_account.account_holder_name).to eq("John Doe")
|
|
33
33
|
expect(us_bank_account.bank_name).to match(/CHASE/)
|
|
34
34
|
expect(us_bank_account.default).to eq(true)
|
|
35
|
-
expect(us_bank_account.ach_mandate.text).to eq("cl mandate text")
|
|
36
35
|
expect(us_bank_account.ach_mandate.accepted_at).to be_a Time
|
|
37
36
|
|
|
38
37
|
expect(us_bank_account.verifications.count).to eq(0)
|
|
@@ -100,7 +99,6 @@ describe Braintree::PaymentMethod do
|
|
|
100
99
|
expect(us_bank_account.account_holder_name).to eq("Dan Schulman")
|
|
101
100
|
expect(us_bank_account.bank_name).to match(/Wells Fargo/)
|
|
102
101
|
expect(us_bank_account.default).to eq(true)
|
|
103
|
-
expect(us_bank_account.ach_mandate.text).to eq("example mandate text")
|
|
104
102
|
expect(us_bank_account.ach_mandate.accepted_at).to be_a Time
|
|
105
103
|
|
|
106
104
|
expect(us_bank_account.verifications.count).to eq(1)
|
|
@@ -135,7 +133,6 @@ describe Braintree::PaymentMethod do
|
|
|
135
133
|
expect(us_bank_account.account_holder_name).to eq("John Doe")
|
|
136
134
|
expect(us_bank_account.bank_name).to match(/CHASE/)
|
|
137
135
|
expect(us_bank_account.default).to eq(true)
|
|
138
|
-
expect(us_bank_account.ach_mandate.text).to eq("cl mandate text")
|
|
139
136
|
expect(us_bank_account.ach_mandate.accepted_at).to be_a Time
|
|
140
137
|
|
|
141
138
|
expect(us_bank_account.verifications.count).to eq(1)
|
|
@@ -5301,6 +5301,61 @@ describe Braintree::Transaction do
|
|
|
5301
5301
|
expect(transaction.shipping_details.international_phone[:national_number]).to eq("3121234567")
|
|
5302
5302
|
end
|
|
5303
5303
|
|
|
5304
|
+
it "accepts processing_merchant_category_code" do
|
|
5305
|
+
result = Braintree::Transaction.sale(
|
|
5306
|
+
:amount => "100.00",
|
|
5307
|
+
:credit_card => {
|
|
5308
|
+
:number => "4111111111111111",
|
|
5309
|
+
:expiration_date => "05/2028"
|
|
5310
|
+
},
|
|
5311
|
+
:processing_merchant_category_code => "5411",
|
|
5312
|
+
)
|
|
5313
|
+
|
|
5314
|
+
expect(result.success?).to eq(true)
|
|
5315
|
+
end
|
|
5316
|
+
|
|
5317
|
+
it "returns validation error for a too long processing_merchant_category_code" do
|
|
5318
|
+
result = Braintree::Transaction.sale(
|
|
5319
|
+
:amount => "100.00",
|
|
5320
|
+
:credit_card => {
|
|
5321
|
+
:number => "4111111111111111",
|
|
5322
|
+
:expiration_date => "05/2028"
|
|
5323
|
+
},
|
|
5324
|
+
:processing_merchant_category_code => "54111",
|
|
5325
|
+
)
|
|
5326
|
+
|
|
5327
|
+
expect(result.success?).to eq(false)
|
|
5328
|
+
expect(result.errors.for(:transaction).on(:processing_merchant_category_code)[0].code).to eq(Braintree::ErrorCodes::Transaction::ProcessingMerchantCategoryCodeIsInvalid)
|
|
5329
|
+
end
|
|
5330
|
+
|
|
5331
|
+
it "returns validation error for an alphanumeric processing_merchant_category_code" do
|
|
5332
|
+
result = Braintree::Transaction.sale(
|
|
5333
|
+
:amount => "100.00",
|
|
5334
|
+
:credit_card => {
|
|
5335
|
+
:number => "4111111111111111",
|
|
5336
|
+
:expiration_date => "05/2028"
|
|
5337
|
+
},
|
|
5338
|
+
:processing_merchant_category_code => "541A",
|
|
5339
|
+
)
|
|
5340
|
+
|
|
5341
|
+
expect(result.success?).to eq(false)
|
|
5342
|
+
expect(result.errors.for(:transaction).on(:processing_merchant_category_code)[0].code).to eq(Braintree::ErrorCodes::Transaction::ProcessingMerchantCategoryCodeIsInvalid)
|
|
5343
|
+
end
|
|
5344
|
+
|
|
5345
|
+
it "returns validation error for a too short processing_merchant_category_code" do
|
|
5346
|
+
result = Braintree::Transaction.sale(
|
|
5347
|
+
:amount => "100.00",
|
|
5348
|
+
:credit_card => {
|
|
5349
|
+
:number => "4111111111111111",
|
|
5350
|
+
:expiration_date => "05/2028"
|
|
5351
|
+
},
|
|
5352
|
+
:processing_merchant_category_code => "541",
|
|
5353
|
+
)
|
|
5354
|
+
|
|
5355
|
+
expect(result.success?).to eq(false)
|
|
5356
|
+
expect(result.errors.for(:transaction).on(:processing_merchant_category_code)[0].code).to eq(Braintree::ErrorCodes::Transaction::ProcessingMerchantCategoryCodeIsInvalid)
|
|
5357
|
+
end
|
|
5358
|
+
|
|
5304
5359
|
it "allows merchant account to be specified" do
|
|
5305
5360
|
result = Braintree::Transaction.sale(
|
|
5306
5361
|
:amount => Braintree::Test::TransactionAmounts::Authorize,
|
|
@@ -6815,6 +6870,34 @@ describe Braintree::Transaction do
|
|
|
6815
6870
|
expect(transaction.acquirer_reference_number).to eq("123456789 091019")
|
|
6816
6871
|
end
|
|
6817
6872
|
|
|
6873
|
+
it "finds a transaction and returns a payment_account_reference if the transaction has one" do
|
|
6874
|
+
transaction = Braintree::Transaction.find("aft_txn")
|
|
6875
|
+
|
|
6876
|
+
expect(transaction.credit_card_details).not_to be_nil
|
|
6877
|
+
expect(transaction.credit_card_details).to respond_to(:payment_account_reference)
|
|
6878
|
+
end
|
|
6879
|
+
|
|
6880
|
+
it "finds a transaction and returns a payment_account_reference in apple_pay_details if the transaction has one" do
|
|
6881
|
+
transaction = Braintree::Transaction.find("apple_pay_transaction")
|
|
6882
|
+
|
|
6883
|
+
expect(transaction.apple_pay_details).not_to be_nil
|
|
6884
|
+
expect(transaction.apple_pay_details).to respond_to(:payment_account_reference)
|
|
6885
|
+
end
|
|
6886
|
+
|
|
6887
|
+
it "finds a transaction and returns a payment_account_reference in google_pay_details if the transaction has one" do
|
|
6888
|
+
transaction = Braintree::Transaction.find("android_pay_card_transaction")
|
|
6889
|
+
|
|
6890
|
+
expect(transaction.google_pay_details).not_to be_nil
|
|
6891
|
+
expect(transaction.google_pay_details).to respond_to(:payment_account_reference)
|
|
6892
|
+
end
|
|
6893
|
+
|
|
6894
|
+
it "finds a transaction and returns a payment_account_reference in google_pay_details for network token if the transaction has one" do
|
|
6895
|
+
transaction = Braintree::Transaction.find("android_pay_network_token_transaction")
|
|
6896
|
+
|
|
6897
|
+
expect(transaction.google_pay_details).not_to be_nil
|
|
6898
|
+
expect(transaction.google_pay_details).to respond_to(:payment_account_reference)
|
|
6899
|
+
end
|
|
6900
|
+
|
|
6818
6901
|
context "disbursement_details" do
|
|
6819
6902
|
it "includes disbursement_details on found transactions" do
|
|
6820
6903
|
found_transaction = Braintree::Transaction.find("deposittransaction")
|
|
@@ -140,7 +140,6 @@ describe Braintree::Transaction do
|
|
|
140
140
|
expect(transaction.us_bank_account_details.account_type).to eq("checking")
|
|
141
141
|
expect(transaction.us_bank_account_details.account_holder_name).to eq("John Doe")
|
|
142
142
|
expect(transaction.us_bank_account_details.bank_name).to match(/CHASE/)
|
|
143
|
-
expect(transaction.us_bank_account_details.ach_mandate.text).to eq("cl mandate text")
|
|
144
143
|
expect(transaction.us_bank_account_details.ach_mandate.accepted_at).to be_a Time
|
|
145
144
|
end
|
|
146
145
|
|
|
@@ -23,7 +23,6 @@ describe Braintree::UsBankAccount do
|
|
|
23
23
|
expect(us_bank_account.account_type).to eq("checking")
|
|
24
24
|
expect(us_bank_account.account_holder_name).to eq("John Doe")
|
|
25
25
|
expect(us_bank_account.bank_name).to match(/CHASE/)
|
|
26
|
-
expect(us_bank_account.ach_mandate.text).to eq("cl mandate text")
|
|
27
26
|
expect(us_bank_account.ach_mandate.accepted_at).to be_a Time
|
|
28
27
|
end
|
|
29
28
|
|
|
@@ -63,7 +62,6 @@ describe Braintree::UsBankAccount do
|
|
|
63
62
|
expect(us_bank_account.account_type).to eq("checking")
|
|
64
63
|
expect(us_bank_account.account_holder_name).to eq("John Doe")
|
|
65
64
|
expect(us_bank_account.bank_name).to match(/CHASE/)
|
|
66
|
-
expect(us_bank_account.ach_mandate.text).to eq("cl mandate text")
|
|
67
65
|
expect(us_bank_account.ach_mandate.accepted_at).to be_a Time
|
|
68
66
|
end
|
|
69
67
|
end
|
|
@@ -96,7 +94,6 @@ describe Braintree::UsBankAccount do
|
|
|
96
94
|
expect(us_bank_account.account_type).to eq("checking")
|
|
97
95
|
expect(us_bank_account.account_holder_name).to eq("John Doe")
|
|
98
96
|
expect(us_bank_account.bank_name).to match(/CHASE/)
|
|
99
|
-
expect(us_bank_account.ach_mandate.text).to eq("cl mandate text")
|
|
100
97
|
expect(us_bank_account.ach_mandate.accepted_at).to be_a Time
|
|
101
98
|
end
|
|
102
99
|
|
|
@@ -159,4 +159,21 @@ describe Braintree::CreditCardVerification do
|
|
|
159
159
|
expect(verification.network_response_text).to eq("Successful approval/completion or V.I.P. PIN verification is successful")
|
|
160
160
|
end
|
|
161
161
|
end
|
|
162
|
+
|
|
163
|
+
describe "credit_card with payment_account_reference" do
|
|
164
|
+
it "includes payment_account_reference in credit_card hash when present" do
|
|
165
|
+
verification = Braintree::CreditCardVerification._new(
|
|
166
|
+
:status => "verified",
|
|
167
|
+
:credit_card => {
|
|
168
|
+
:bin => "401288",
|
|
169
|
+
:last_4 => "1881",
|
|
170
|
+
:card_type => "Visa",
|
|
171
|
+
:payment_account_reference => "V0010013019339005665779448477"
|
|
172
|
+
},
|
|
173
|
+
)
|
|
174
|
+
|
|
175
|
+
expect(verification.credit_card).to be_a(Hash)
|
|
176
|
+
expect(verification.credit_card[:payment_account_reference]).to eq("V0010013019339005665779448477")
|
|
177
|
+
end
|
|
178
|
+
end
|
|
162
179
|
end
|
|
@@ -25,4 +25,13 @@ describe Braintree::ApplePayDetails do
|
|
|
25
25
|
card = Braintree::ApplePayDetails._new(:gateway, {:purchase => "No"})
|
|
26
26
|
expect(card.purchase).to eq("No")
|
|
27
27
|
end
|
|
28
|
+
|
|
29
|
+
describe "payment_account_reference" do
|
|
30
|
+
it "returns the payment account reference when present" do
|
|
31
|
+
details = Braintree::Transaction::ApplePayDetails.new(
|
|
32
|
+
:payment_account_reference => "V0010013019339005665779448477",
|
|
33
|
+
)
|
|
34
|
+
expect(details.payment_account_reference).to eq("V0010013019339005665779448477")
|
|
35
|
+
end
|
|
36
|
+
end
|
|
28
37
|
end
|
|
@@ -39,7 +39,7 @@ describe Braintree::Transaction::CreditCardDetails do
|
|
|
39
39
|
:image_url => "example.com/visa.png",
|
|
40
40
|
:unique_number_identifier => "abc123",
|
|
41
41
|
)
|
|
42
|
-
expect(details.inspect).to eq(%(#<token: "token", bin: "123456", business: "No", last_4: "6789", card_type: "Visa", commercial: "Unknown", consumer: "Unknown", corporate: "Unknown", country_of_issuance: "Lilliput", customer_location: "US", debit: "Yes", durbin_regulated: "No", expiration_date: "05/2012", healthcare: "No", image_url: "example.com/visa.png", issuing_bank: "Gulliver Bank", payroll: "Unknown", prepaid: "Yes", prepaid_reloadable: "Yes", product_id: "Unknown", purchase: "Unknown", cardholder_name: "The Cardholder", unique_number_identifier: "abc123">))
|
|
42
|
+
expect(details.inspect).to eq(%(#<token: "token", bin: "123456", business: "No", last_4: "6789", card_type: "Visa", commercial: "Unknown", consumer: "Unknown", corporate: "Unknown", country_of_issuance: "Lilliput", customer_location: "US", debit: "Yes", durbin_regulated: "No", expiration_date: "05/2012", healthcare: "No", image_url: "example.com/visa.png", issuing_bank: "Gulliver Bank", payroll: "Unknown", prepaid: "Yes", prepaid_reloadable: "Yes", product_id: "Unknown", purchase: "Unknown", cardholder_name: "The Cardholder", unique_number_identifier: "abc123", payment_account_reference: nil>))
|
|
43
43
|
end
|
|
44
44
|
end
|
|
45
45
|
|
|
@@ -67,4 +67,13 @@ describe Braintree::Transaction::CreditCardDetails do
|
|
|
67
67
|
expect(details.is_network_tokenized?).to eq(false)
|
|
68
68
|
end
|
|
69
69
|
end
|
|
70
|
+
|
|
71
|
+
describe "payment_account_reference" do
|
|
72
|
+
it "returns the payment account reference when present" do
|
|
73
|
+
details = Braintree::Transaction::CreditCardDetails.new(
|
|
74
|
+
:payment_account_reference => "V0010013019339005665779448477",
|
|
75
|
+
)
|
|
76
|
+
expect(details.payment_account_reference).to eq("V0010013019339005665779448477")
|
|
77
|
+
end
|
|
78
|
+
end
|
|
70
79
|
end
|
|
@@ -25,4 +25,13 @@ describe Braintree::GooglePayDetails do
|
|
|
25
25
|
card = Braintree::GooglePayDetails._new(:gateway, {:purchase => "No"})
|
|
26
26
|
expect(card.purchase).to eq("No")
|
|
27
27
|
end
|
|
28
|
+
|
|
29
|
+
context "payment_account_reference" do
|
|
30
|
+
it "returns the payment account reference when present" do
|
|
31
|
+
details = Braintree::Transaction::GooglePayDetails.new(
|
|
32
|
+
:payment_account_reference => "V0010013019339005665779448477",
|
|
33
|
+
)
|
|
34
|
+
expect(details.payment_account_reference).to eq("V0010013019339005665779448477")
|
|
35
|
+
end
|
|
36
|
+
end
|
|
28
37
|
end
|
|
@@ -35,7 +35,7 @@ describe Braintree::TransactionGateway do
|
|
|
35
35
|
expect(Braintree::TransactionGateway._create_signature).to match([
|
|
36
36
|
:amount, :billing_address_id, :channel, :currency_iso_code, :customer_id, :device_data,
|
|
37
37
|
:discount_amount, :exchange_rate_quote_id, :foreign_retailer,
|
|
38
|
-
:merchant_account_id, :order_id, :payment_method_nonce, :payment_method_token,
|
|
38
|
+
:merchant_account_id, :order_id, :payment_method_nonce, :payment_method_token, :processing_merchant_category_code,
|
|
39
39
|
:product_sku, :purchase_order_number, :service_fee_amount, :shared_billing_address_id,
|
|
40
40
|
:shared_customer_id, :shared_payment_method_nonce, :shared_payment_method_token,
|
|
41
41
|
:shared_shipping_address_id, :shipping_address_id, :shipping_amount, :shipping_tax_amount,
|
|
@@ -157,6 +157,44 @@ describe Braintree::Transaction do
|
|
|
157
157
|
expect(transaction.credit_card_details.issuing_bank).to eq("Mr Tumnus")
|
|
158
158
|
end
|
|
159
159
|
|
|
160
|
+
describe "payment_account_reference in transaction details" do
|
|
161
|
+
it "exposes payment_account_reference in credit_card_details" do
|
|
162
|
+
transaction = Braintree::Transaction._new(
|
|
163
|
+
:gateway,
|
|
164
|
+
:credit_card => {
|
|
165
|
+
:bin => "401288",
|
|
166
|
+
:last_4 => "1881",
|
|
167
|
+
:card_type => "Visa",
|
|
168
|
+
:payment_account_reference => "V0010013019339005665779448477"
|
|
169
|
+
},
|
|
170
|
+
)
|
|
171
|
+
expect(transaction.credit_card_details.payment_account_reference).to eq("V0010013019339005665779448477")
|
|
172
|
+
end
|
|
173
|
+
|
|
174
|
+
it "exposes payment_account_reference in apple_pay_details" do
|
|
175
|
+
transaction = Braintree::Transaction._new(
|
|
176
|
+
:gateway,
|
|
177
|
+
:apple_pay => {
|
|
178
|
+
:payment_instrument_name => "Apple Pay",
|
|
179
|
+
:payment_account_reference => "V0010013019339005665779448477"
|
|
180
|
+
},
|
|
181
|
+
)
|
|
182
|
+
expect(transaction.apple_pay_details.payment_account_reference).to eq("V0010013019339005665779448477")
|
|
183
|
+
end
|
|
184
|
+
|
|
185
|
+
it "exposes payment_account_reference in google_pay_details" do
|
|
186
|
+
transaction = Braintree::Transaction._new(
|
|
187
|
+
:gateway,
|
|
188
|
+
:android_pay_card => {
|
|
189
|
+
:virtual_card_type => "Visa",
|
|
190
|
+
:payment_account_reference => "V0010013019339005665779448477"
|
|
191
|
+
},
|
|
192
|
+
)
|
|
193
|
+
expect(transaction.google_pay_details.payment_account_reference).to eq("V0010013019339005665779448477")
|
|
194
|
+
end
|
|
195
|
+
|
|
196
|
+
end
|
|
197
|
+
|
|
160
198
|
it "sets up network token attributes in network_token_details" do
|
|
161
199
|
transaction = Braintree::Transaction._new(
|
|
162
200
|
:gateway,
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: braintree
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 4.
|
|
4
|
+
version: 4.32.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Braintree
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2025-10-
|
|
11
|
+
date: 2025-10-23 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: builder
|
|
@@ -420,7 +420,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
420
420
|
- !ruby/object:Gem::Version
|
|
421
421
|
version: '0'
|
|
422
422
|
requirements: []
|
|
423
|
-
rubygems_version: 3.
|
|
423
|
+
rubygems_version: 3.2.5
|
|
424
424
|
signing_key:
|
|
425
425
|
specification_version: 4
|
|
426
426
|
summary: Braintree Ruby Server SDK
|