Skip to content
This repository was archived by the owner on May 20, 2019. It is now read-only.

Commit 485b89f

Browse files
Merge pull request #6 from magento/2.3-develop
update branch
2 parents 9143820 + 5a298ad commit 485b89f

File tree

339 files changed

+5608
-2428
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

339 files changed

+5608
-2428
lines changed

app/autoload.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,9 @@
2828
/* 'composer install' validation */
2929
if (file_exists($vendorAutoload)) {
3030
$composerAutoloader = include $vendorAutoload;
31+
} else if (file_exists("{$vendorDir}/autoload.php")) {
32+
$vendorAutoload = "{$vendorDir}/autoload.php";
33+
$composerAutoloader = include $vendorAutoload;
3134
} else {
3235
throw new \Exception(
3336
'Vendor autoload is not found. Please run \'composer install\' under application root directory.'

app/bootstrap.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,15 +11,15 @@
1111
#ini_set('display_errors', 1);
1212

1313
/* PHP version validation */
14-
if (!defined('PHP_VERSION_ID') || !(PHP_VERSION_ID === 70002 || PHP_VERSION_ID === 70004 || PHP_VERSION_ID >= 70006)) {
14+
if (!defined('PHP_VERSION_ID') || PHP_VERSION_ID < 70103) {
1515
if (PHP_SAPI == 'cli') {
16-
echo 'Magento supports 7.0.2, 7.0.4, and 7.0.6 or later. ' .
17-
'Please read http://devdocs.magento.com/guides/v2.2/install-gde/system-requirements.html';
16+
echo 'Magento supports PHP 7.1.3 or later. ' .
17+
'Please read https://devdocs.magento.com/guides/v2.3/install-gde/system-requirements-tech.html';
1818
} else {
1919
echo <<<HTML
2020
<div style="font:12px/1.35em arial, helvetica, sans-serif;">
21-
<p>Magento supports PHP 7.0.2, 7.0.4, and 7.0.6 or later. Please read
22-
<a target="_blank" href="http://devdocs.magento.com/guides/v2.2/install-gde/system-requirements.html">
21+
<p>Magento supports PHP 7.1.3 or later. Please read
22+
<a target="_blank" href="https://devdocs.magento.com/guides/v2.3/install-gde/system-requirements-tech.html">
2323
Magento System Requirements</a>.
2424
</div>
2525
HTML;

app/code/Magento/Analytics/Test/Mftf/Test/AdminConfigurationIndustryTest.xml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,6 @@
1717
<severity value="MAJOR"/>
1818
<testCaseId value="MAGETWO-63898"/>
1919
<group value="analytics"/>
20-
<skip>
21-
<issueId value="MAGETWO-96223"/>
22-
</skip>
2320
</annotations>
2421

2522
<actionGroup ref="LoginActionGroup" stepKey="loginAsAdmin"/>
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
<?php
2+
/**
3+
* Copyright © Magento, Inc. All rights reserved.
4+
* See COPYING.txt for license details.
5+
*/
6+
declare(strict_types=1);
7+
8+
namespace Magento\Authorizenet\Block\Adminhtml\Order\View\Info;
9+
10+
use Magento\Framework\Phrase;
11+
use Magento\Payment\Block\ConfigurableInfo;
12+
13+
/**
14+
* Payment information block for Authorize.net payment method
15+
*/
16+
class PaymentDetails extends ConfigurableInfo
17+
{
18+
/**
19+
* Returns localized label for payment info block
20+
*
21+
* @param string $field
22+
* @return string | Phrase
23+
*/
24+
protected function getLabel($field)
25+
{
26+
return __($field);
27+
}
28+
}

app/code/Magento/Authorizenet/Model/Directpost.php

Lines changed: 20 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ class Directpost extends \Magento\Authorizenet\Model\Authorizenet implements Tra
2727
/**
2828
* @var string
2929
*/
30-
protected $_infoBlockType = \Magento\Payment\Block\Info::class;
30+
protected $_infoBlockType = \Magento\Authorizenet\Block\Adminhtml\Order\View\Info\PaymentDetails::class;
3131

3232
/**
3333
* Payment Method feature
@@ -371,8 +371,7 @@ public function void(\Magento\Payment\Model\InfoInterface $payment)
371371
}
372372

373373
/**
374-
* Refund the amount
375-
* Need to decode last 4 digits for request.
374+
* Refund the amount need to decode last 4 digits for request.
376375
*
377376
* @param \Magento\Framework\DataObject|\Magento\Payment\Model\InfoInterface $payment
378377
* @param float $amount
@@ -626,6 +625,14 @@ protected function fillPaymentByResponse(\Magento\Framework\DataObject $payment)
626625
$payment->setIsTransactionPending(true)
627626
->setIsFraudDetected(true);
628627
}
628+
629+
$additionalInformationKeys = explode(',', $this->getValue('paymentInfoKeys'));
630+
foreach ($additionalInformationKeys as $paymentInfoKey) {
631+
$paymentInfoValue = $response->getDataByKey($paymentInfoKey);
632+
if ($paymentInfoValue !== null) {
633+
$payment->setAdditionalInformation($paymentInfoKey, $paymentInfoValue);
634+
}
635+
}
629636
}
630637

631638
/**
@@ -682,6 +689,7 @@ protected function matchAmount($amount)
682689

683690
/**
684691
* Operate with order using information from Authorize.net.
692+
*
685693
* Authorize order or authorize and capture it.
686694
*
687695
* @param \Magento\Sales\Model\Order $order
@@ -858,7 +866,7 @@ public function getConfigInterface()
858866
* Getter for specified value according to set payment method code
859867
*
860868
* @param mixed $key
861-
* @param null $storeId
869+
* @param int|string|null|\Magento\Store\Model\Store $storeId
862870
* @return mixed
863871
*/
864872
public function getValue($key, $storeId = null)
@@ -918,10 +926,12 @@ public function fetchTransactionInfo(\Magento\Payment\Model\InfoInterface $payme
918926
$payment->setIsTransactionDenied(true);
919927
}
920928
$this->addStatusCommentOnUpdate($payment, $response, $transactionId);
921-
return [];
929+
return $response->getData();
922930
}
923931

924932
/**
933+
* Add statuc comment on update.
934+
*
925935
* @param \Magento\Sales\Model\Order\Payment $payment
926936
* @param \Magento\Framework\DataObject $response
927937
* @param string $transactionId
@@ -996,8 +1006,9 @@ protected function getTransactionResponse($transactionId)
9961006
}
9971007

9981008
/**
999-
* @return \Psr\Log\LoggerInterface
1009+
* Get psr logger.
10001010
*
1011+
* @return \Psr\Log\LoggerInterface
10011012
* @deprecated 100.1.0
10021013
*/
10031014
private function getPsrLogger()
@@ -1038,7 +1049,9 @@ private function getOrderIncrementId(): string
10381049
}
10391050

10401051
/**
1041-
* Checks if filter action is Report Only. Transactions that trigger this filter are processed as normal,
1052+
* Checks if filter action is Report Only.
1053+
*
1054+
* Transactions that trigger this filter are processed as normal,
10421055
* but are also reported in the Merchant Interface as triggering this filter.
10431056
*
10441057
* @param string $fdsFilterAction

app/code/Magento/Authorizenet/etc/config.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@
3232
<cgi_url>https://secure.authorize.net/gateway/transact.dll</cgi_url>
3333
<cgi_url_td_test_mode>https://apitest.authorize.net/xml/v1/request.api</cgi_url_td_test_mode>
3434
<cgi_url_td>https://api2.authorize.net/xml/v1/request.api</cgi_url_td>
35+
<paymentInfoKeys>x_card_type,x_account_number,x_avs_code,x_auth_code,x_response_reason_text,x_cvv2_resp_code</paymentInfoKeys>
3536
</authorizenet_directpost>
3637
</payment>
3738
</default>

app/code/Magento/Authorizenet/etc/di.xml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,4 +35,9 @@
3535
</argument>
3636
</arguments>
3737
</type>
38+
<type name="Magento\Authorizenet\Block\Adminhtml\Order\View\Info\PaymentDetails">
39+
<arguments>
40+
<argument name="config" xsi:type="object">Magento\Authorizenet\Model\Directpost</argument>
41+
</arguments>
42+
</type>
3843
</config>

app/code/Magento/Authorizenet/i18n/en_US.csv

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,3 +67,9 @@ Debug,Debug
6767
"Minimum Order Total","Minimum Order Total"
6868
"Maximum Order Total","Maximum Order Total"
6969
"Sort Order","Sort Order"
70+
"x_card_type","Credit Card Type"
71+
"x_account_number", "Credit Card Number"
72+
"x_avs_code","AVS Response Code"
73+
"x_auth_code","Processor Authentication Code"
74+
"x_response_reason_text","Processor Response Text"
75+
"x_cvv2_resp_code","CVV2 Response Code"

app/code/Magento/Authorizenet/view/adminhtml/templates/order/view/info/fraud_details.phtml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,8 @@ $fraudDetails = $payment->getAdditionalInformation('fraud_details');
4444
<?php endif; ?>
4545

4646
<?php if(!empty($fraudDetails['fraud_filters'])): ?>
47-
<b><?= $block->escapeHtml(__('Fraud Filters')) ?>:
48-
</b></br>
47+
<strong><?= $block->escapeHtml(__('Fraud Filters')) ?>:
48+
</strong></br>
4949
<?php foreach($fraudDetails['fraud_filters'] as $filter): ?>
5050
<?= $block->escapeHtml($filter['name']) ?>:
5151
<?= $block->escapeHtml($filter['action']) ?>

app/code/Magento/Authorizenet/view/frontend/requirejs-config.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,8 @@
66
var config = {
77
map: {
88
'*': {
9-
transparent: 'Magento_Payment/js/transparent'
9+
transparent: 'Magento_Payment/js/transparent',
10+
'Magento_Payment/transparent': 'Magento_Payment/js/transparent'
1011
}
1112
}
1213
};

app/code/Magento/Backend/view/adminhtml/templates/system/cache/additional.phtml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,10 @@ $permissions = $block->getData('permissions');
1111
?>
1212
<?php if ($permissions && $permissions->hasAccessToAdditionalActions()): ?>
1313
<div class="additional-cache-management">
14+
<h2>
15+
<span><?= $block->escapeHtml(__('Additional Cache Management')); ?></span>
16+
</h2>
1417
<?php if ($permissions->hasAccessToFlushCatalogImages()): ?>
15-
<h2>
16-
<span><?= $block->escapeHtml(__('Additional Cache Management')); ?></span>
17-
</h2>
1818
<p>
1919
<button onclick="setLocation('<?= $block->escapeJs($block->getCleanImagesUrl()); ?>')" type="button">
2020
<?= $block->escapeHtml(__('Flush Catalog Images Cache')); ?>

app/code/Magento/Backup/Test/Mftf/Test/AdminCreateAndDeleteBackupsTest.xml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,7 @@
1818
<testCaseId value="MAGETWO-94176"/>
1919
<group value="backup"/>
2020
<skip>
21-
<issueId value="MQE-1187"/>
22-
<issueId value="DEVOPS-3512"/>
21+
<issueId value="MC-5807"/>
2322
</skip>
2423
</annotations>
2524

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!--
3+
/**
4+
* Copyright © Magento, Inc. All rights reserved.
5+
* See COPYING.txt for license details.
6+
*/
7+
-->
8+
<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
9+
xsi:noNamespaceSchemaLocation="../../../../../../../dev/tests/acceptance/vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Test/etc/actionGroupSchema.xsd">
10+
11+
<actionGroup name="AdminOrderBraintreeFillActionGroup">
12+
<!--Select Braintree Payment method on Admin Order Create Page-->
13+
<click stepKey="chooseBraintree" selector="{{NewOrderSection.creditCardBraintree}}"/>
14+
<waitForPageLoad stepKey="waitForBraintreeConfigs" time="5"/>
15+
<click stepKey="openCardTypes" selector="{{NewOrderSection.openCardTypes}}"/>
16+
<waitForPageLoad stepKey="waitForCardTypes" time="3"/>
17+
<click stepKey="chooseCardType" selector="{{NewOrderSection.masterCard}}"/>
18+
<waitForPageLoad stepKey="waitForCardSelected" time="3"/>
19+
20+
<!--Choose Master Card from drop-down list-->
21+
<switchToIFrame stepKey="switchToCardNumber" selector="{{NewOrderSection.cardFrame}}"/>
22+
<fillField stepKey="fillCardNumber" selector="{{NewOrderSection.creditCardNumber}}" userInput="{{PaymentAndShippingInfo.cardNumber}}"/>
23+
<waitForPageLoad stepKey="waitForFillCardNumber" time="1"/>
24+
<switchToIFrame stepKey="switchBackFromCard"/>
25+
26+
<!--Fill expire date-->
27+
<switchToIFrame stepKey="switchToExpirationMonth" selector="{{NewOrderSection.monthFrame}}"/>
28+
<fillField stepKey="fillMonth" selector="{{NewOrderSection.expirationMonth}}" userInput="{{PaymentAndShippingInfo.month}}"/>
29+
<waitForPageLoad stepKey="waitForFillMonth" time="1"/>
30+
<switchToIFrame stepKey="switchBackFromMonth"/>
31+
<switchToIFrame stepKey="switchToExpirationYear" selector="{{NewOrderSection.yearFrame}}"/>
32+
<fillField stepKey="fillYear" selector="{{NewOrderSection.expirationYear}}" userInput="{{PaymentAndShippingInfo.year}}"/>
33+
<waitForPageLoad stepKey="waitForFillYear" time="1"/>
34+
<switchToIFrame stepKey="switchBackFromYear"/>
35+
36+
<!--Fill CVW code-->
37+
<switchToIFrame stepKey="switchToCVV" selector="{{NewOrderSection.cvvFrame}}"/>
38+
<fillField stepKey="fillCVV" selector="{{NewOrderSection.cvv}}" userInput="{{PaymentAndShippingInfo.cvv}}"/>
39+
<wait stepKey="waitForFillCVV" time="1"/>
40+
<switchToIFrame stepKey="switchBackFromCVV"/>
41+
</actionGroup>
42+
</actionGroups>

app/code/Magento/Braintree/Test/Mftf/ActionGroup/ConfigureBraintreeActionGroup.xml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
*/
77
-->
88
<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
9-
xsi:noNamespaceSchemaLocation="../../../../../../../dev/tests/acceptance/vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Test/etc/actionGroupSchema.xsd">
9+
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd">
1010

1111
<actionGroup name="ConfigureBraintree">
1212
<!-- GoTo ConfigureBraintree fields -->
@@ -46,4 +46,8 @@
4646
<waitForElementVisible selector="{{BraintreeConfiguraionSection.successfulMessage}}" stepKey="waitForSuccessfullyConfigured" time="10"/>
4747
</actionGroup>
4848

49+
<actionGroup name="DisableBrainTree">
50+
<magentoCLI stepKey="disableBrainTree" command="config:set payment/braintree/active 0"/>
51+
<magentoCLI stepKey="disableBrainTreePaypal" command="config:set payment/braintree_paypal/active 0"/>
52+
</actionGroup>
4953
</actionGroups>

app/code/Magento/Braintree/Test/Mftf/ActionGroup/CreateNewOrderActionGroup.xml

Lines changed: 1 addition & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -8,28 +8,7 @@
88
<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
99
xsi:noNamespaceSchemaLocation="../../../../../../../dev/tests/acceptance/vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Test/etc/actionGroupSchema.xsd">
1010

11-
<actionGroup name="CreateNewOrderActionGroup">
12-
<click stepKey="createNewOrder" selector="{{NewOrderSection.createNewOrder}}"/>
13-
<waitForPageLoad stepKey="waitForCustomersList" time="3"/>
14-
<click stepKey="chooseCustomer" selector="{{NewOrderSection.customer}}"/>
15-
<waitForPageLoad stepKey="waitForOrderPage" time="3"/>
16-
<click stepKey="addProducts" selector="{{NewOrderSection.addProducts}}"/>
17-
<waitForPageLoad stepKey="waitForProducts" time="3"/>
18-
<click stepKey="chooseProducts" selector="{{NewOrderSection.chooseProduct}}"/>
19-
<waitForPageLoad stepKey="waitForProductChoose" time="3"/>
20-
<click stepKey="addSelectedProduct" selector="{{NewOrderSection.addSelectedProduct}}"/>
21-
<waitForAjaxLoad stepKey="waitForChoose" time="3"/>
22-
<click stepKey="openAddresses" selector="{{NewOrderSection.openAddresses}}"/>
23-
<click stepKey="chooseAddress" selector="{{NewOrderSection.chooseAddress}}"/>
24-
<fillField stepKey="fillState" selector="{{NewOrderSection.state}}" userInput="Yerevan"/>
25-
<scrollTo stepKey="scrollTo" selector="#order-methods"/>
26-
<waitForPageLoad stepKey="waitForMethods" time="3"/>
27-
<click stepKey="startJSMethodExecution" selector="{{NewOrderSection.openShippingMethods}}"/>
28-
<waitForPageLoad stepKey="waitForJSMethodExecution" time="3"/>
29-
<click stepKey="openShippingMethods" selector="{{NewOrderSection.openShippingMethods}}"/>
30-
<waitForPageLoad stepKey="waitForShippingMethods" time="3"/>
31-
<click stepKey="chooseShippingMethods" selector="{{NewOrderSection.shippingMethod}}"/>
32-
<waitForPageLoad stepKey="waitForShippingMethodChoose" time="4"/>
11+
<actionGroup name="useBraintreeForMasterCard">
3312
<click stepKey="chooseBraintree" selector="{{NewOrderSection.creditCardBraintree}}"/>
3413
<waitForPageLoad stepKey="waitForBraintreeConfigs" time="5"/>
3514
<click stepKey="openCardTypes" selector="{{NewOrderSection.openCardTypes}}"/>
@@ -56,11 +35,5 @@
5635
<fillField stepKey="fillCVV" selector="{{NewOrderSection.cvv}}" userInput="{{PaymentAndShippingInfo.cvv}}"/>
5736
<wait stepKey="waitForFillCVV" time="1"/>
5837
<switchToIFrame stepKey="switchBackFromCVV"/>
59-
60-
<click stepKey="submitOrder" selector="{{NewOrderSection.submitOrder}}"/>
61-
<waitForPageLoad stepKey="waitForSaveConfig" time="5"/>
62-
<waitForElementVisible selector="{{NewOrderSection.successMessage}}" stepKey="waitForSuccessMessage" time="1"/>
63-
6438
</actionGroup>
65-
6639
</actionGroups>

app/code/Magento/Braintree/Test/Mftf/Data/BraintreeData.xml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@
4242
<requiredEntity type="merchant_id">MerchantId</requiredEntity>
4343
<requiredEntity type="public_key">PublicKey</requiredEntity>
4444
<requiredEntity type="private_key">PrivateKey</requiredEntity>
45+
<requiredEntity type="active">Status</requiredEntity>
4546
</entity>
4647
<entity name="BraintreeTitle" type="title">
4748
<data key="value">Credit Card (Braintree)</data>
@@ -128,7 +129,7 @@
128129
<data key="firstName">John</data>
129130
<data key="lastName">Smith</data>
130131
<data key="password">admin123</data>
131-
<data key="email">[email protected]</data>
132+
<data key="email" unique="prefix">[email protected]</data>
132133
</entity>
133134

134135
<entity name="PaymentAndShippingInfo" type="data">

app/code/Magento/Braintree/Test/Mftf/Section/AdminMenuSection.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
<element name="sales" type="button" selector="//li[@id='menu-magento-sales-sales']"/>
1414
<element name="catalog" type="button" selector="//li[@id='menu-magento-catalog-catalog']"/>
1515
<element name="customers" type="button" selector="//li[@id='menu-magento-customer-customer']"/>
16-
<element name="marketing" type="button" selector="//li[@id='//li[@id='menu-magento-backend-marketing']']"/>
16+
<element name="marketing" type="button" selector="//li[@id='menu-magento-backend-marketing']"/>
1717
<element name="content" type="button" selector="//li[@id='menu-magento-backend-content']"/>
1818
<element name="reports" type="button" selector="//li[@id='menu-magento-reports-report']"/>
1919
<element name="stores" type="button" selector="//li[@id='menu-magento-backend-stores']"/>

0 commit comments

Comments
 (0)