diff --git a/.travis.yml b/.travis.yml index 064a19c..ee5e51d 100644 --- a/.travis.yml +++ b/.travis.yml @@ -22,7 +22,7 @@ before_script: - composer update --prefer-source script: - vendor/bin/phpunit --coverage-text --coverage-clover=coverage.clover - - vendor/bin/phpcs -p --standard=$TRAVIS_BUILD_DIR/vendor/ongr/ongr-strict-standard/ONGR --ignore=vendor/,Tests/app/,Resources/public/ ./ + - vendor/bin/phpcs -p --standard=$TRAVIS_BUILD_DIR/vendor/ongr/ongr-strict-standard/Ongr --ignore=vendor/,Tests/app/,Resources/public/ ./ after_script: - wget https://scrutinizer-ci.com/ocular.phar - php ocular.phar code-coverage:upload --format=php-clover coverage.clover diff --git a/DependencyInjection/ONGROXIDConnectorExtension.php b/DependencyInjection/ONGROXIDConnectorExtension.php index 57dd889..7d48f3e 100755 --- a/DependencyInjection/ONGROXIDConnectorExtension.php +++ b/DependencyInjection/ONGROXIDConnectorExtension.php @@ -86,9 +86,7 @@ public function load(array $configs, ContainerBuilder $container) */ protected function loadModifiers($config, LoaderInterface $loader) { - $toLoadModifiers = [ - 'product', 'category', 'content', - ]; + $toLoadModifiers = ['product', 'category', 'content']; foreach ($toLoadModifiers as $modifier) { if ($config['modifiers'] === [] || in_array($modifier, $config['modifiers'])) { @@ -97,8 +95,13 @@ protected function loadModifiers($config, LoaderInterface $loader) } $toLoadRelations = [ - 'product', 'category', 'content', - 'oxaccessoire2article', 'oxactions2article', 'oxobject2action', 'oxfield2shop', + 'product', + 'category', + 'content', + 'oxaccessoire2article', + 'oxactions2article', + 'oxobject2action', + 'oxfield2shop', ]; foreach ($toLoadRelations as $relation) { diff --git a/Tests/Functional/Overall/DataSyncTest.php b/Tests/Functional/Overall/DataSyncTest.php index 9e8c526..3e0c16c 100644 --- a/Tests/Functional/Overall/DataSyncTest.php +++ b/Tests/Functional/Overall/DataSyncTest.php @@ -60,7 +60,6 @@ public function testDataSync() ); // The part of "sync execute". - $esManager = $this->getServiceContainer()->get('es.manager'); $esManager->getConnection()->dropAndCreateIndex(); @@ -137,10 +136,9 @@ public function testDataSync() 'stock' => 2, 'vendor' => 'Vendor Title for PRODUCT TWO', 'manufacturer' => 'Naish', - 'categories' => - [ - 0 => 'fada9485f003c731b7fad08b873214e0', - ], + 'categories' => [ + 0 => 'fada9485f003c731b7fad08b873214e0', + ], ], ], 'TestBundle:CategoryDocument' => [ @@ -152,14 +150,12 @@ public function testDataSync() 'left' => 4, 'right' => 5, 'root_id' => '30e44ab83fdee7564.23264141', - 'attributes' => - [ - 0 => - [ - 'title' => 'testAttribute', - 'pos' => 9999, - ], + 'attributes' => [ + 0 => [ + 'title' => 'testAttribute', + 'pos' => 9999, ], + ], ], ], 'TestBundle:ContentDocument' => [ diff --git a/Tests/Unit/Modifier/ProductModifierTest.php b/Tests/Unit/Modifier/ProductModifierTest.php index e588dd3..775f660 100755 --- a/Tests/Unit/Modifier/ProductModifierTest.php +++ b/Tests/Unit/Modifier/ProductModifierTest.php @@ -176,7 +176,7 @@ public function testModifySkip() /** * @param Article $parent * - * @return Article[] ; + * @return Article[] */ private function getVariants($parent) { diff --git a/composer.json b/composer.json index 0064b38..da51e22 100755 --- a/composer.json +++ b/composer.json @@ -19,8 +19,8 @@ }, "require-dev": { "phpunit/phpunit": "~4.2", - "ongr/ongr-strict-standard": "~1.0.0-beta", - "squizlabs/php_codesniffer": "~1.5" + "ongr/ongr-strict-standard": "~2.1", + "squizlabs/php_codesniffer": "~2.0" }, "autoload": { "psr-4": {