Skip to content

Commit c2a9d42

Browse files
author
Oleksii Korshenko
authored
Merge pull request #930 from magento-engcom/MAGETWO-65199-PR-8685
Public Pull Request: #8685
2 parents e01d54c + a3a5c73 commit c2a9d42

File tree

918 files changed

+1548
-1988
lines changed

Some content is hidden

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

918 files changed

+1548
-1988
lines changed

.travis.yml

+2-3
Original file line numberDiff line numberDiff line change
@@ -26,12 +26,11 @@ cache:
2626
directories: $HOME/.composer/cache
2727
matrix:
2828
exclude:
29-
- php: 7.0
29+
- php: 5.6.29
3030
env: TEST_SUITE=static
3131
before_install: ./dev/travis/before_install.sh
3232
install: composer install --no-interaction --prefer-dist
3333
before_script: ./dev/travis/before_script.sh
3434
script:
35-
- cd dev/tests/$TEST_SUITE
3635
- test $TEST_SUITE = "static" && TEST_FILTER='--filter "Magento\\Test\\Php\\LiveCodeTest"' || true
37-
- phpunit $TEST_FILTER
36+
- phpunit -c dev/tests/$TEST_SUITE $TEST_FILTER

app/code/Magento/AdminNotification/Model/System/Message/Baseurl.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
use Magento\Store\Model\Store;
1010

1111
/**
12-
* @deprecated
12+
* @deprecated
1313
*/
1414
class Baseurl implements \Magento\Framework\Notification\MessageInterface
1515
{

app/code/Magento/AdminNotification/Setup/InstallSchema.php

-1
Original file line numberDiff line numberDiff line change
@@ -120,6 +120,5 @@ public function install(SchemaSetupInterface $setup, ModuleContextInterface $con
120120
$installer->getConnection()->createTable($table);
121121

122122
$installer->endSetup();
123-
124123
}
125124
}

app/code/Magento/AdvancedPricingImportExport/Test/Unit/Model/Import/AdvancedPricing/Validator/WebsiteTest.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ class WebsiteTest extends \PHPUnit_Framework_TestCase
1313
/**
1414
* @var \Magento\Store\Model\WebSite|\PHPUnit_Framework_MockObject_MockObject
1515
*/
16-
protected $webSiteModel;
16+
protected $webSiteModel;
1717

1818
/**
1919
* @var \Magento\CatalogImportExport\Model\Import\Product\StoreResolver|\PHPUnit_Framework_MockObject_MockObject

app/code/Magento/Analytics/Controller/Adminhtml/Subscription/Postpone.php

-1
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,6 @@ public function __construct(
5555
$this->notificationTime = $notificationTime;
5656
$this->logger = $logger;
5757
parent::__construct($context);
58-
5958
}
6059

6160
/**

app/code/Magento/Analytics/Model/FileRecorder.php

-1
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,6 @@ public function recordNewFile(EncodedContext $encodedContext)
7878
$this->removeOldFile($fileInfo, $directory);
7979

8080
return true;
81-
8281
}
8382

8483
/**

app/code/Magento/Analytics/Model/ReportWriter.php

-1
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,6 @@ public function write(WriteInterface $directory, $path)
8080
if (!$headers) {
8181
$headers = array_keys($row);
8282
$stream->writeCsv($headers);
83-
8483
}
8584
$stream->writeCsv($row);
8685
}

app/code/Magento/Analytics/ReportXml/Config/Mapper.php

-1
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,6 @@ public function execute($configData)
3131
$entityData = array_shift($queryData['source']);
3232
$queries[$queryData['name']] = $queryData;
3333
$queries[$queryData['name']]['source'] = $entityData;
34-
3534
}
3635
return $queries;
3736
}

app/code/Magento/Analytics/ReportXml/DB/ColumnsResolver.php

-1
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,6 @@ public function getColumns(SelectBuilder $selectBuilder, $entityConfig)
6363
if (isset($attributeData['group'])) {
6464
$group[$columnAlias] = $expression;
6565
}
66-
6766
}
6867
$selectBuilder->setGroup(array_merge($selectBuilder->getGroup(), $group));
6968
return $columns;

app/code/Magento/Analytics/ReportXml/Query.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ class Query implements \JsonSerializable
2525
private $selectHydrator;
2626

2727
/**
28-
* @var string
28+
* @var string
2929
*/
3030
private $connectionName;
3131

app/code/Magento/Analytics/ReportXml/ReportProvider.php

-1
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,5 @@ public function getReport($name, SearchCriteria $criteria = null)
7474
$connection = $this->connectionFactory->getConnection($query->getConnectionName());
7575
$statement = $connection->query($query->getSelect());
7676
return $this->iteratorFactory->create($statement, $this->getIteratorName($query));
77-
7877
}
7978
}

app/code/Magento/Analytics/Test/Unit/Model/Config/Backend/CollectionTimeTest.php

-1
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,6 @@ public function testAfterSave()
7676
Value::class,
7777
$this->collectionTime->afterSave()
7878
);
79-
8079
}
8180

8281
/**

app/code/Magento/Analytics/view/adminhtml/templates/dashboard/section.phtml

+1
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
* Copyright © 2013-2017 Magento, Inc. All rights reserved.
44
* See COPYING.txt for license details.
55
*/
6+
// @codingStandardsIgnoreFile
67
?>
78

89
<section class="dashboard-advanced-reports" data-index="dashboard-advanced-reports">

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

+6-9
Original file line numberDiff line numberDiff line change
@@ -281,15 +281,14 @@ protected function processCapture($result, $payment)
281281
switch ($result->getXResponseCode()) {
282282
case self::RESPONSE_CODE_APPROVED:
283283
case self::RESPONSE_CODE_HELD:
284-
if (
285-
in_array(
286-
$result->getXResponseReasonCode(),
287-
[
284+
if (in_array(
285+
$result->getXResponseReasonCode(),
286+
[
288287
self::RESPONSE_REASON_CODE_APPROVED,
289288
self::RESPONSE_REASON_CODE_PENDING_REVIEW,
290289
self::RESPONSE_REASON_CODE_PENDING_REVIEW_AUTHORIZED
291290
]
292-
)
291+
)
293292
) {
294293
if (!$payment->getParentTransactionId()
295294
|| $result->getXTransId() != $payment->getParentTransactionId()
@@ -534,8 +533,7 @@ public function validateResponse()
534533
{
535534
$response = $this->getResponse();
536535
//md5 check
537-
if (
538-
!$this->getConfigData('trans_md5')
536+
if (!$this->getConfigData('trans_md5')
539537
|| !$this->getConfigData('login')
540538
|| !$response->isValidHash($this->getConfigData('trans_md5'), $this->getConfigData('login'))
541539
) {
@@ -802,8 +800,7 @@ protected function declineOrder(\Magento\Sales\Model\Order $order, $message = ''
802800
{
803801
try {
804802
$response = $this->getResponse();
805-
if (
806-
$voidPayment && $response->getXTransId() && strtoupper($response->getXType())
803+
if ($voidPayment && $response->getXTransId() && strtoupper($response->getXType())
807804
== self::REQUEST_TYPE_AUTH_ONLY
808805
) {
809806
$order->getPayment()->setTransactionId(null)->setParentTransactionId($response->getXTransId())->void();

app/code/Magento/Backend/Block/Dashboard/Sales.php

-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
*/
66
namespace Magento\Backend\Block\Dashboard;
77

8-
98
/**
109
* Adminhtml dashboard sales statistics bar
1110
*

app/code/Magento/Backend/Block/Dashboard/Totals.php

-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
*/
1212
namespace Magento\Backend\Block\Dashboard;
1313

14-
1514
class Totals extends \Magento\Backend\Block\Dashboard\Bar
1615
{
1716
/**

app/code/Magento/Backend/Block/System/Design/Edit/Tab/General.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ protected function _prepareForm()
6565
'required' => true
6666
]
6767
);
68-
$renderer = $this->getLayout()->createBlock(
68+
$renderer = $this->getLayout()->createBlock(
6969
\Magento\Backend\Block\Store\Switcher\Form\Renderer\Fieldset\Element::class
7070
);
7171
$field->setRenderer($renderer);

app/code/Magento/Backend/Block/Widget/Grid/Column/Filter/Store.php

+1
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
class Store extends \Magento\Backend\Block\Widget\Grid\Column\Filter\AbstractFilter
1313
{
1414
const ALL_STORE_VIEWS = '0';
15+
1516
/**
1617
* @var \Magento\Store\Model\System\Store
1718
*/

app/code/Magento/Backend/Block/Widget/Grid/Column/Renderer/Country.php

-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@
99
*/
1010
namespace Magento\Backend\Block\Widget\Grid\Column\Renderer;
1111

12-
1312
class Country extends \Magento\Backend\Block\Widget\Grid\Column\Renderer\AbstractRenderer
1413
{
1514
/**

app/code/Magento/Backend/Model/Config/SessionLifetime/BackendModel.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ public function beforeSave()
2626
throw new LocalizedException(
2727
__('Admin session lifetime must be less than or equal to 31536000 seconds (one year)')
2828
);
29-
} else if ($value < self::MIN_LIFETIME) {
29+
} elseif ($value < self::MIN_LIFETIME) {
3030
throw new LocalizedException(
3131
__('Admin session lifetime must be greater than or equal to 60 seconds')
3232
);

app/code/Magento/Backend/Model/Locale/Manager.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ public function switchBackendInterfaceLocale($localeCode)
7070
}
7171

7272
/**
73-
* Get general interface locale
73+
* Get general interface locale
7474
*
7575
* @return string
7676
*/

app/code/Magento/Backend/Model/Menu/Item/Validator.php

+1-2
Original file line numberDiff line numberDiff line change
@@ -82,8 +82,7 @@ public function validate($data)
8282
}
8383

8484
foreach ($data as $param => $value) {
85-
if (
86-
$data[$param] !== null
85+
if ($data[$param] !== null
8786
&& isset(
8887
$this->_validators[$param]
8988
) && !$this->_validators[$param]->isValid(

app/code/Magento/Backend/Model/View/Layout/ConditionInterface.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
* </argument>
2020
* </arguments>
2121
* </type>
22-
*
22+
*
2323
* Registered condition can be used by ui component declaration in layout
2424
*
2525
* <uiComponent name="form" condition="condition::identifier" />

app/code/Magento/Backend/Model/View/Layout/ConditionPool.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
/**
1212
* Class ConditionPool
13-
*
13+
*
1414
* Registry for \Magento\Backend\Model\View\Layout\ConditionInterface
1515
* @see usage details in \Magento\Backend\Model\View\Layout\ConditionInterface description
1616
*

app/code/Magento/Backend/Model/View/Layout/FilterInterface.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
* </argument>
2424
* </arguments>
2525
* </type>
26-
*
26+
*
2727
*/
2828
interface FilterInterface
2929
{

app/code/Magento/Backend/Model/View/Layout/Reader/Block.php

+9
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,15 @@
1313
*/
1414
class Block extends Layout\Reader\Block
1515
{
16+
/**
17+
* Initialize dependencies.
18+
*
19+
* @param Layout\ScheduledStructure\Helper $helper
20+
* @param Layout\Argument\Parser $argumentParser
21+
* @param Layout\ReaderPool $readerPool
22+
* @param InterpreterInterface $argumentInterpreter
23+
* @param string|null $scopeType
24+
*/
1625
public function __construct(
1726
Layout\ScheduledStructure\Helper $helper,
1827
Layout\Argument\Parser $argumentParser,

app/code/Magento/Backend/Service/V1/ModuleService.php

+1
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ class ModuleService implements ModuleServiceInterface
1515
* @var \Magento\Framework\Module\ModuleListInterface
1616
*/
1717
protected $moduleList;
18+
1819
/**
1920
* @param \Magento\Framework\Module\ModuleListInterface $moduleList
2021
*/

app/code/Magento/Backend/Test/Unit/App/Action/Plugin/AuthenticationTest.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ public function testProcessNotLoggedInUser($isIFrameParam, $isAjaxParam, $isForw
120120
if ($isIFrameParam) {
121121
$getParamCalls = 1;
122122
$actionName = 'deniedIframe';
123-
} else if ($isAjaxParam) {
123+
} elseif ($isAjaxParam) {
124124
$getParamCalls = 2;
125125
$actionName = 'deniedJson';
126126
} else {

app/code/Magento/Backend/Test/Unit/Block/Page/System/Config/Robots/ResetTest.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111

1212
/**
1313
* Class ResetTest
14-
* @deprecated
14+
* @deprecated
1515
* @package Magento\Backend\Test\Unit\Block\Page\System\Config\Robots
1616
*/
1717
class ResetTest extends \PHPUnit_Framework_TestCase

app/code/Magento/Backend/Test/Unit/Controller/Adminhtml/Cache/CleanStaticFilesTest.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ protected function setUp()
4848
->disableOriginalConstructor()
4949
->getMock();
5050
$objectHelper = new \Magento\Framework\TestFramework\Unit\Helper\ObjectManager($this);
51-
$context = $objectHelper->getObject(
51+
$context = $objectHelper->getObject(
5252
\Magento\Backend\App\Action\Context::class,
5353
[
5454
'objectManager' => $this->objectManagerMock,
@@ -58,7 +58,7 @@ protected function setUp()
5858
]
5959
);
6060

61-
$this->controller = $objectHelper->getObject(
61+
$this->controller = $objectHelper->getObject(
6262
\Magento\Backend\Controller\Adminhtml\Cache\CleanStaticFiles::class,
6363
['context' => $context,]
6464
);

app/code/Magento/Backup/Model/Config/Backend/Cron.php

-2
Original file line numberDiff line numberDiff line change
@@ -23,11 +23,9 @@ class Cron extends \Magento\Framework\App\Config\Value
2323
/** @var \Magento\Framework\App\Config\ValueFactory */
2424
protected $_configValueFactory;
2525

26-
2726
/** @var string */
2827
protected $_runModelPath = '';
2928

30-
3129
/**
3230
* @param \Magento\Framework\Model\Context $context
3331
* @param \Magento\Framework\Registry $registry

app/code/Magento/Braintree/Block/Adminhtml/Form/Field/Countries.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ protected function _toHtml()
4747

4848
/**
4949
* Sets name for input element
50-
*
50+
*
5151
* @param string $value
5252
* @return $this
5353
*/

app/code/Magento/Braintree/Block/Adminhtml/Form/Field/CountryCreditCard.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ class CountryCreditCard extends AbstractFieldArray
2525

2626
/**
2727
* Returns renderer for country element
28-
*
28+
*
2929
* @return Countries
3030
*/
3131
protected function getCountryRenderer()
@@ -42,7 +42,7 @@ protected function getCountryRenderer()
4242

4343
/**
4444
* Returns renderer for country element
45-
*
45+
*
4646
* @return CcTypes
4747
*/
4848
protected function getCcTypesRenderer()

app/code/Magento/Braintree/Block/Customer/PayPal/VaultTokenRenderer.php

+7
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,13 @@ class VaultTokenRenderer extends AbstractTokenRenderer
2121
*/
2222
private $config;
2323

24+
/**
25+
* Initialize dependencies.
26+
*
27+
* @param Template\Context $context
28+
* @param Config $config
29+
* @param array $data
30+
*/
2431
public function __construct(
2532
Template\Context $context,
2633
Config $config,

app/code/Magento/Braintree/Controller/Adminhtml/Payment/GetNonce.php

-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
*/
66
namespace Magento\Braintree\Controller\Adminhtml\Payment;
77

8-
98
/**
109
* Class GetNonce
1110
*/

app/code/Magento/Braintree/Controller/Payment/GetNonce.php

-1
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,6 @@ public function execute()
6565
$customerId = $this->session->getCustomerId();
6666
$result = $this->command->execute(['public_hash' => $publicHash, 'customer_id' => $customerId])->get();
6767
$response->setData(['paymentMethodNonce' => $result['paymentMethodNonce']]);
68-
6968
} catch (\Exception $e) {
7069
$this->logger->critical($e);
7170
return $this->processBadRequest($response);

app/code/Magento/Braintree/Gateway/Config/PayPal/Config.php

+8
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,14 @@ class Config extends \Magento\Payment\Gateway\Config\Config
3535
*/
3636
private $icon = [];
3737

38+
/**
39+
* Initialize dependencies.
40+
*
41+
* @param ScopeConfigInterface $scopeConfig
42+
* @param CcConfig $ccConfig
43+
* @param null $methodCode
44+
* @param string $pathPattern
45+
*/
3846
public function __construct(
3947
ScopeConfigInterface $scopeConfig,
4048
CcConfig $ccConfig,

0 commit comments

Comments
 (0)