Skip to content

Commit a86d528

Browse files
committed
Merge remote-tracking branch 'origin/MAGETWO-58376' into 2.1-develop-pr1
2 parents 3021072 + 1c7f70d commit a86d528

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

app/code/Magento/Paypal/Model/Payflow/Transparent.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -167,6 +167,7 @@ public function authorize(InfoInterface $payment, $amount)
167167
$request->setData('trxtype', self::TRXTYPE_AUTH_ONLY);
168168
$request->setData('origid', $token);
169169
$request->setData('amt', $this->formatPrice($amount));
170+
$request->setData('currency', $order->getBaseCurrencyCode());
170171

171172
$response = $this->postRequest($request, $this->getConfig());
172173
$this->processErrors($response);

app/code/Magento/Paypal/Test/Unit/Model/Payflow/TransparentTest.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ protected function initializationAuthorizeMock()
122122
$this->orderMock = $this->getMockBuilder('Magento\Sales\Model\Order')
123123
->setMethods([
124124
'getCustomerId', 'getBillingAddress', 'getShippingAddress', 'getCustomerEmail',
125-
'getId', 'getIncrementId'
125+
'getId', 'getIncrementId', 'getBaseCurrencyCode'
126126
])
127127
->disableOriginalConstructor()
128128
->getMock();
@@ -164,6 +164,9 @@ protected function buildRequestData()
164164
$this->paymentMock->expects($this->once())
165165
->method('getOrder')
166166
->willReturn($this->orderMock);
167+
$this->orderMock->expects($this->once())
168+
->method('getBaseCurrencyCode')
169+
->willReturn('USD');
167170
$this->orderMock->expects($this->once())
168171
->method('getBillingAddress')
169172
->willReturn($this->addressBillingMock);

0 commit comments

Comments
 (0)