GildedRose-Refactoring-Kata/php/ecs.php
Pen-y-Fan 10d3cf7f5a Add PHP8
- update README.md with latest PHP information
- update composer.json to support PHP 7.3 to PHP8
  - active support for PHP 7.2 ended 6 Dec 2020
  - PHP8 was released 26-Nov-2020
  - update the dependencies
- PHPUnit now version 9.5 and config file updated
- ECS now version 9.3 and config file changed from `ecs.yaml` to `ecs.php`

ApprovalTest removed, in line with latest readme, all set for refactoring :)

Tested with PHP 7.3, 7.4 and 8.0 one failing "fixme" != "foo" test!
2021-05-03 16:02:47 +01:00

37 lines
986 B
PHP

<?php
declare(strict_types=1);
use PhpCsFixer\Fixer\ArrayNotation\ArraySyntaxFixer;
use Symfony\Component\DependencyInjection\Loader\Configurator\ContainerConfigurator;
use Symplify\EasyCodingStandard\ValueObject\Option;
use Symplify\EasyCodingStandard\ValueObject\Set\SetList;
return static function (ContainerConfigurator $containerConfigurator): void {
$services = $containerConfigurator->services();
$services->set(ArraySyntaxFixer::class)
->call('configure', [[
'syntax' => 'short',
]]);
$parameters = $containerConfigurator->parameters();
$parameters->set(Option::PATHS, [
__DIR__ . '/fixtures',
__DIR__ . '/src',
__DIR__ . '/tests',
]);
$parameters->set
(Option::SETS,
[
SetList::CLEAN_CODE,
SetList::COMMON,
SetList::PSR_12,
]
);
$parameters->set(Option::INDENTATION, "spaces");
$parameters->set(Option::LINE_ENDING, "\n");
};