-
Notifications
You must be signed in to change notification settings - Fork 2.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Elavon: Multi-currency support #3210
Conversation
2b5513c
to
b005b98
Compare
Elavon returns an error for any API request that includes a currency UNLESS the merchant's terminal is setup for multi-currency. Previously we NEVER sent the currency, so only the default currency worked. Now, we only send the `ssl_transaction_currency` field if the currency field is provided. Elavon Multi-Currency Conversion (MCC) documentation: https://developer.elavon.com/#/api/eb6e9106-0172-4305-bc5a-b3ebe832f823.rcosoomi/documents?converge-integration-guide/book/processing_options/../../book/processing_options/mcc.html ECS-272 Unit: 29 tests, 141 assertions, 0 failures, 0 errors, 0 pendings, 0 omissions, 0 notifications 100% passed Remote: 25 tests, 110 assertions, 0 failures, 0 errors, 0 pendings, 0 omissions, 0 notifications 100% passed Closes activemerchant#3210
end | ||
|
||
def test_successful_purchase_with_multi_currency | ||
assert response = @multi_currency_gateway.purchase(@amount, @credit_card, @options.merge(currency: 'JPY', multi_currency: true)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we want to test the gateway-level and option-level flags separately?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think that's a holdover from before I changed to use a gateway-level flag. I'll add a new test.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Suggested an additional test, otherwise LGTM 👍
Send the currency in the ssl_transaction_currency field only if the user has specified they are using multi-currency. The multi-currency flag can be set with either a gateway or transaction level field. Using multi-currency depends on the merchant's multi-currency terminal setting at Elavon. ECS-272 Unit: 31 tests, 150 assertions, 0 failures, 0 errors, 0 pendings, 0 omissions, 0 notifications 100% passed Remote: 27 tests, 120 assertions, 0 failures, 0 errors, 0 pendings, 0 omissions, 0 notifications 100% passed closes activemerchant#3210
43776dd
to
8db319a
Compare
Elavon returns an error for any API request that includes a currency UNLESS the merchant's terminal is setup for multi-currency. Previously we NEVER sent the currency, so only the default currency worked. Now, we only send the `ssl_transaction_currency` field if the currency field is provided. Elavon Multi-Currency Conversion (MCC) documentation: https://developer.elavon.com/#/api/eb6e9106-0172-4305-bc5a-b3ebe832f823.rcosoomi/documents?converge-integration-guide/book/processing_options/../../book/processing_options/mcc.html ECS-272 Unit: 29 tests, 141 assertions, 0 failures, 0 errors, 0 pendings, 0 omissions, 0 notifications 100% passed Remote: 25 tests, 110 assertions, 0 failures, 0 errors, 0 pendings, 0 omissions, 0 notifications 100% passed Closes activemerchant#3210
Send the currency in the ssl_transaction_currency field only if the user has specified they are using multi-currency. The multi-currency flag can be set with either a gateway or transaction level field. Using multi-currency depends on the merchant's multi-currency terminal setting at Elavon. ECS-272 Unit: 31 tests, 150 assertions, 0 failures, 0 errors, 0 pendings, 0 omissions, 0 notifications 100% passed Remote: 27 tests, 120 assertions, 0 failures, 0 errors, 0 pendings, 0 omissions, 0 notifications 100% passed closes activemerchant#3210
Send the currency in the ssl_transaction_currency field only if the
user has specified they are using multi-currency. The multi-currency
flag can be set with either a gateway or transaction level field.
Using multi-currency depends on the merchant's multi-currency terminal
setting at Elavon.
ECS-272
Unit:
31 tests, 150 assertions, 0 failures, 0 errors, 0 pendings, 0 omissions, 0 notifications
100% passed
Remote:
26 tests, 115 assertions, 0 failures, 0 errors, 0 pendings, 0 omissions, 0 notifications
100% passed