diff --git a/.github/workflows/php.yml b/.github/workflows/php.yml index e4514c1..3413f0e 100644 --- a/.github/workflows/php.yml +++ b/.github/workflows/php.yml @@ -10,11 +10,23 @@ on: jobs: test: - name: Test PHP ${{ matrix.php-versions }} + name: Test PHP ${{ matrix.php.version }} ${{ matrix.php.composer_flags }} runs-on: ubuntu-latest strategy: matrix: - php-versions: ['8.0', '8.1', '8.2'] + php: + - version: '8.2' + composer_flags: --prefer-lowest + - version: '8.3' + composer_flags: --prefer-lowest + - version: '8.4' + composer_flags: --prefer-lowest + - version: '8.2' + composer_flags: --prefer-stable + - version: '8.3' + composer_flags: --prefer-stable + - version: '8.4' + composer_flags: --prefer-stable steps: - uses: actions/checkout@v3 @@ -27,7 +39,7 @@ jobs: - name: Setup PHP uses: shivammathur/setup-php@v2 with: - php-version: ${{ matrix.php-versions }} + php-version: ${{ matrix.php.version }} extensions: curl, mbstring, intl, libxml, simplexml coverage: xdebug @@ -40,17 +52,17 @@ jobs: uses: actions/cache@v3 with: path: ${{ steps.composer-cache-dir.outputs.dir }} - key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }} - restore-keys: ${{ runner.os }}-composer- + key: ${{ runner.os }}-composer-${{ matrix.php.composer_flags }}-${{ hashFiles('**/composer.json') }} + restore-keys: ${{ runner.os }}-composer-${{ matrix.php.composer_flags }}- - name: Install dependencies - run: (test -d vendor && echo vendor directory exists) || composer install --prefer-dist --no-progress --no-suggest + run: (test -d vendor && echo vendor directory exists) || composer update ${{ matrix.php.composer_flags }} --no-progress --no-suggest - name: Run PHPUnit run: ./bin/phpunit --coverage-text --coverage-clover clover.xml - name: Upload Scrutinizer coverage - if: matrix.php-versions == '8.0' + if: matrix.php.version == '8.2' && matrix.php.composer_flags == '--prefer-stable' uses: sudo-bot/action-scrutinizer@latest with: - cli-args: "--format=php-clover clover.xml" \ No newline at end of file + cli-args: "--format=php-clover clover.xml --revision=${{ github.event.pull_request.head.sha || github.sha }}" \ No newline at end of file diff --git a/.gitignore b/.gitignore index 00d0c60..bbec756 100644 --- a/.gitignore +++ b/.gitignore @@ -8,3 +8,4 @@ composer.lock /.coveralls.yml /clover.xml /coveralls-upload.json +/rector.php diff --git a/.php-cs-fixer.dist.php b/.php-cs-fixer.dist.php index 5869849..a6f5de3 100644 --- a/.php-cs-fixer.dist.php +++ b/.php-cs-fixer.dist.php @@ -22,7 +22,7 @@ 'no_singleline_whitespace_before_semicolons' => true, 'no_spaces_after_function_name' => true, 'no_spaces_around_offset' => true, - 'no_superfluous_phpdoc_tags' => false, + 'no_superfluous_phpdoc_tags' => ['allow_mixed' => true, 'remove_inheritdoc' => false, 'allow_unused_params' => true], 'no_unused_imports' => true, 'no_useless_else' => true, 'no_whitespace_before_comma_in_array' => true, @@ -38,7 +38,6 @@ 'phpdoc_types_order' => ['null_adjustment' => 'always_first'], 'protected_to_private' => true, 'single_blank_line_at_eof' => true, - 'single_blank_line_before_namespace' => true, 'single_line_comment_style' => false, 'single_line_throw' => false, 'single_quote' => false, diff --git a/.scrutinizer.yml b/.scrutinizer.yml index c5ea315..965dc90 100644 --- a/.scrutinizer.yml +++ b/.scrutinizer.yml @@ -1,4 +1,5 @@ build: + image: default-bionic nodes: analysis: project_setup: diff --git a/composer.json b/composer.json index ab253b3..3fc7382 100644 --- a/composer.json +++ b/composer.json @@ -3,24 +3,24 @@ "description": "A library to manage patch requests", "keywords": ["rest", "patch", "api", "symfony", "bundle"], "require": { - "php": "^8.0", + "php": "^8.2", "ext-json": "*", - "symfony/property-access": "^4.0 || ^5.0 || ^6.0", - "symfony/http-foundation": "^4.0 || ^5.0 || ^6.0", - "symfony/options-resolver": "^4.0 || ^5.0 || ^6.0", - "symfony/dependency-injection": "^4.0 || ^5.0 || ^6.0", - "symfony/http-kernel": "^4.0 || ^5.0 || ^6.0", - "symfony/config": "^4.0 || ^5.0 || ^6.0", - "symfony/event-dispatcher": "^4.0 || ^5.0 || ^6.0", - "mattiabasone/phpcollection": "^0.7.0" + "symfony/property-access": "^6.0 || ^7.0", + "symfony/http-foundation": "^6.0 || ^7.0", + "symfony/options-resolver": "^6.0 || ^7.0", + "symfony/dependency-injection": "^6.0 || ^7.0", + "symfony/http-kernel": "^6.0 || ^7.0", + "symfony/config": "^6.0 || ^7.0", + "symfony/event-dispatcher": "^6.0 || ^7.0", + "mattiabasone/phpcollection": "^1.0.0" }, "require-dev": { - "friendsofphp/php-cs-fixer": "^3.1", - "phpunit/phpunit": "^9.5", + "friendsofphp/php-cs-fixer": "^3.70", + "phpunit/phpunit": "^11.5", "mockery/mockery": "^1.4", "yohang/finite": "^1.2", "doctrine/orm": "^2.9", - "phpspec/prophecy-phpunit": "^2.0", + "phpspec/prophecy-phpunit": "^2.3", "phpstan/phpstan": "^1.0", "phpstan/phpstan-doctrine": "^1.0", "phpstan/phpstan-mockery": "^1.0" diff --git a/phpstan.neon b/phpstan.neon index 04878e7..6c3d58c 100644 --- a/phpstan.neon +++ b/phpstan.neon @@ -6,11 +6,8 @@ parameters: level: 6 #https://phpstan.org/user-guide/rule-levels paths: - src - - tests - checkGenericClassInNonGenericObjectType: false ignoreErrors: - '#no value type specified in iterable type#' - '#Call to an undefined method Symfony\\Component\\Config\\Definition\\Builder\\NodeDefinition::children\(\)#' - - '#Call to an undefined method Prophecy\\Prophecy#' - '#Method Cypress\\PatchManager\\OperationMatcher::getUnmatchedOperations\(\) should return PhpCollection\\Sequence but returns PhpCollection\\AbstractSequence#' - - '#Property Cypress\\PatchManager\\Tests\\FakeObjects\\Subject(A|B)::\$a is never read, only written#' \ No newline at end of file + - '#Property Cypress\\PatchManager\\Exception\\InvalidJsonRequestContent::\$message has no type specified#' diff --git a/phpunit.xml.dist b/phpunit.xml.dist index 0b4db54..09f1813 100644 --- a/phpunit.xml.dist +++ b/phpunit.xml.dist @@ -1,24 +1,23 @@ - - - - + + ./src src/*Bundle/Resources - src/DataFixtures - + diff --git a/src/PatchManager/Bundle/DependencyInjection/Configuration.php b/src/PatchManager/Bundle/DependencyInjection/Configuration.php index 418d93c..1f51eb3 100644 --- a/src/PatchManager/Bundle/DependencyInjection/Configuration.php +++ b/src/PatchManager/Bundle/DependencyInjection/Configuration.php @@ -1,5 +1,7 @@ handleGenericConfig($config, $container, $loaderHandlers); } - /** - * @param array $config - * @param ContainerBuilder $container - * @param Loader\XmlFileLoader $loaderHandlers - */ private function handleGenericConfig( array $config, ContainerBuilder $container, @@ -60,10 +58,6 @@ private function handleGenericConfig( $container->setParameter('patch_manager.strict_mode', $config['strict_mode']); } - /** - * @param Loader\XmlFileLoader $loaderHandlers - * @param ContainerBuilder $container - */ private function handleStateMachine(Loader\XmlFileLoader $loaderHandlers, ContainerBuilder $container): void { if (!interface_exists('Finite\Factory\FactoryInterface')) { diff --git a/src/PatchManager/Bundle/PatchManagerBundle.php b/src/PatchManager/Bundle/PatchManagerBundle.php index 848f499..c28a7fb 100644 --- a/src/PatchManager/Bundle/PatchManagerBundle.php +++ b/src/PatchManager/Bundle/PatchManagerBundle.php @@ -1,5 +1,7 @@ requestStack = $requestStack; } - /** - * @return null|string - */ public function getRequestBody(): ?string { $request = $this->requestStack->getCurrentRequest(); diff --git a/src/PatchManager/Event/PatchManagerEvent.php b/src/PatchManager/Event/PatchManagerEvent.php index 42f55df..26b08df 100644 --- a/src/PatchManager/Event/PatchManagerEvent.php +++ b/src/PatchManager/Event/PatchManagerEvent.php @@ -1,5 +1,7 @@ matchedPatchOperation = $matchedPatchOperation; $this->subject = $subject; } - /** - * @return MatchedPatchOperation - */ public function getMatchedPatchOperation(): MatchedPatchOperation { return $this->matchedPatchOperation; } - /** - * @return Patchable - */ public function getSubject(): Patchable { return $this->subject; diff --git a/src/PatchManager/Event/PatchManagerEvents.php b/src/PatchManager/Event/PatchManagerEvents.php index 8fe598e..8670602 100644 --- a/src/PatchManager/Event/PatchManagerEvents.php +++ b/src/PatchManager/Event/PatchManagerEvents.php @@ -1,5 +1,7 @@ factoryInterface = $factoryInterface; } - /** - * @param Patchable $subject - * @param OperationData $operationData - */ public function handle(Patchable $subject, OperationData $operationData): void { $sm = $this->factoryInterface->get($subject); @@ -39,8 +31,6 @@ public function handle(Patchable $subject, OperationData $operationData): void /** * the operation name - * - * @return string */ public function getName(): string { @@ -51,8 +41,6 @@ public function getName(): string * use the OptionResolver instance to configure the required and optional fields that needs to be passed * with the request body. See http://symfony.com/doc/current/components/options_resolver.html to check all * possible options - * - * @param OptionsResolver $optionsResolver */ public function configureOptions(OptionsResolver $optionsResolver): void { @@ -64,9 +52,6 @@ public function configureOptions(OptionsResolver $optionsResolver): void /** * whether the handler is able to handle the given subject - * - * @param Patchable $subject - * @return bool */ public function canHandle(Patchable $subject): bool { diff --git a/src/PatchManager/MatchedPatchOperation.php b/src/PatchManager/MatchedPatchOperation.php index 66c7bd2..9b029df 100644 --- a/src/PatchManager/MatchedPatchOperation.php +++ b/src/PatchManager/MatchedPatchOperation.php @@ -1,45 +1,28 @@ operationData = $operationData; $this->handler = $handler; } - /** - * @param array $operationData - * @param PatchOperationHandler $handler - * @return MatchedPatchOperation - */ public static function create(array $operationData, PatchOperationHandler $handler): MatchedPatchOperation { return new self($operationData, $handler); } - /** - * @param string $operationName - * @return bool - */ public function matchFor(string $operationName): bool { return $operationName === $this->handler->getName(); @@ -47,8 +30,6 @@ public function matchFor(string $operationName): bool /** * call handle on the handler - * - * @param Patchable $patchable */ public function process(Patchable $patchable): void { @@ -59,10 +40,7 @@ public function process(Patchable $patchable): void $this->handler->handle($patchable, $options); } - /** - * @return string - */ - public function getOpName() + public function getOpName(): string { return $this->handler->getName(); } diff --git a/src/PatchManager/OperationData.php b/src/PatchManager/OperationData.php index aad7c46..0778aff 100644 --- a/src/PatchManager/OperationData.php +++ b/src/PatchManager/OperationData.php @@ -1,5 +1,7 @@ */ public function getOp(): Option { return $this->get(Operations::OP_KEY_NAME); } - /** - * @return Map - */ public function getData(): Map { $operationData = new Map($this->elements); @@ -35,13 +29,12 @@ public function getData(): Map return $operationData; } - /** - * @param array $keys - * @return Sequence - */ public function diffKeys(array $keys): Sequence { - $filtered = array_filter($this->getData()->keys(), fn ($key) => !in_array($key, $keys)); + $filtered = array_filter( + $this->getData()->keys(), + static fn ($key) => !in_array($key, $keys) + ); return new Sequence($filtered); } diff --git a/src/PatchManager/OperationMatcher.php b/src/PatchManager/OperationMatcher.php index 315eede..da618ed 100644 --- a/src/PatchManager/OperationMatcher.php +++ b/src/PatchManager/OperationMatcher.php @@ -1,5 +1,7 @@ handlers = new Sequence(); $this->operations = $operations; } - /** - * @param PatchOperationHandler $handler - */ public function addHandler(PatchOperationHandler $handler): void { $this->handlers->add($handler); @@ -43,7 +33,6 @@ public function addHandler(PatchOperationHandler $handler): void * @throws Exception\MissingOperationNameRequest * @throws Exception\MissingOperationRequest * @throws Exception\InvalidJsonRequestContent - * @return Sequence */ public function getMatchedOperations($subject): Sequence { @@ -73,7 +62,6 @@ function (Sequence $matchedOperations, array $operationData) use ($handlers, $su * @throws Exception\InvalidJsonRequestContent * @throws Exception\MissingOperationNameRequest * @throws Exception\MissingOperationRequest - * @return Sequence */ public function getUnmatchedOperations($subject): Sequence { diff --git a/src/PatchManager/PatchManager.php b/src/PatchManager/PatchManager.php index c3f7a93..507ef1f 100644 --- a/src/PatchManager/PatchManager.php +++ b/src/PatchManager/PatchManager.php @@ -1,5 +1,7 @@ strictMode = $strictMode; } - /** - * @param EventDispatcherInterface $eventDispatcherInterface - */ public function setEventDispatcherInterface(EventDispatcherInterface $eventDispatcherInterface): void { $this->eventDispatcherInterface = $eventDispatcherInterface; @@ -59,10 +48,6 @@ public function handle($subject): void $this->handleSubject($subject, $matchedOperations); } - /** - * @param MatchedPatchOperation $matchedPatchOperation - * @param Patchable $subject - */ protected function doHandle(MatchedPatchOperation $matchedPatchOperation, Patchable $subject): void { $event = new PatchManagerEvent($matchedPatchOperation, $subject); @@ -74,10 +59,6 @@ protected function doHandle(MatchedPatchOperation $matchedPatchOperation, Patcha /** * dispatch events if the eventDispatcher is present - * - * @param PatchManagerEvent $event - * @param string $opName - * @param string $type */ protected function dispatchEvents(PatchManagerEvent $event, string $opName, string $type): void { @@ -97,7 +78,6 @@ protected function dispatchEvents(PatchManagerEvent $event, string $opName, stri * @throws Exception\MissingOperationNameRequest * @throws Exception\MissingOperationRequest * @throws HandlerNotFoundException - * @return Sequence */ private function getMatchedOperations($subject): Sequence { @@ -110,14 +90,14 @@ private function getMatchedOperations($subject): Sequence } /** - * @param array|Patchable|\Traversable $subject a Patchable instance or a collection of instances - * @param Sequence $matchedOperations + * @param iterable|Patchable $subject a Patchable instance or a collection of instances * @throws Exception\MissingOperationNameRequest * @throws Exception\MissingOperationRequest + * @throws Exception\InvalidJsonRequestContent */ - private function handleSubject($subject, Sequence $matchedOperations): void + private function handleSubject(Patchable|iterable $subject, Sequence $matchedOperations): void { - if (is_array($subject) || $subject instanceof \Traversable) { + if (is_iterable($subject)) { $this->handleMany($subject); return; @@ -129,12 +109,12 @@ private function handleSubject($subject, Sequence $matchedOperations): void } /** - * @param array|\Traversable $subjects + * @param array|\Traversable $subjects * @throws Exception\InvalidJsonRequestContent * @throws Exception\MissingOperationNameRequest * @throws Exception\MissingOperationRequest */ - private function handleMany($subjects): void + private function handleMany(iterable $subjects): void { foreach ($subjects as $subject) { foreach ($this->operationMatcher->getMatchedOperations($subject) as $matchedPatchOperation) { diff --git a/src/PatchManager/PatchOperationHandler.php b/src/PatchManager/PatchOperationHandler.php index 32fb809..bfaba31 100644 --- a/src/PatchManager/PatchOperationHandler.php +++ b/src/PatchManager/PatchOperationHandler.php @@ -1,5 +1,7 @@ adapter = $adapter; @@ -28,7 +24,6 @@ public function __construct(Adapter $adapter) * @throws InvalidJsonRequestContent * @throws MissingOperationNameRequest * @throws MissingOperationRequest - * @return Sequence */ public function all(): Sequence { @@ -47,17 +42,19 @@ public function all(): Sequence } /** - * @param string $string * @throws InvalidJsonRequestContent * @throws MissingOperationRequest - * @return array */ private function parseJson(?string $string): array { + if (is_null($string)) { + throw new InvalidJsonRequestContent(); + } + try { - $json = json_decode($string, true, 512, JSON_THROW_ON_ERROR); + $json = json_decode($string, associative: true, flags: JSON_THROW_ON_ERROR); - //we need this control because json_decode('2', true, 512, JSON_THROW_ON_ERROR) returns a valid result: int(2) + // we need this control because json_decode('2', true, 512, JSON_THROW_ON_ERROR) returns a valid result: int(2) if (!is_array($json)) { throw new MissingOperationRequest(); } @@ -68,10 +65,6 @@ private function parseJson(?string $string): array } } - /** - * @param array $operations - * @return Sequence - */ private function toSequence(array $operations): Sequence { $operations = $this->isAssociative($operations) ? [$operations] : $operations; @@ -79,11 +72,7 @@ private function toSequence(array $operations): Sequence return new Sequence($operations); } - /** - * @param array $arr - * @return bool - */ - private function isAssociative($arr): bool + private function isAssociative(array $arr): bool { return array_keys($arr) !== range(0, count($arr) - 1); } diff --git a/tests/PatchManager/Bundle/DependencyInjection/PatchManagerCompilerPassTest.php b/tests/PatchManager/Bundle/DependencyInjection/PatchManagerCompilerPassTest.php index 3282b49..931b8de 100644 --- a/tests/PatchManager/Bundle/DependencyInjection/PatchManagerCompilerPassTest.php +++ b/tests/PatchManager/Bundle/DependencyInjection/PatchManagerCompilerPassTest.php @@ -10,12 +10,8 @@ class PatchManagerCompilerPassTest extends PatchManagerTestCase { - /** @var ObjectProphecy */ private ObjectProphecy $cb; - /** - * @var PatchManagerCompilerPass - */ private PatchManagerCompilerPass $compilerPass; public function setUp(): void diff --git a/tests/PatchManager/Handler/FakeObjects/DataDoctrineSubject.php b/tests/PatchManager/Handler/FakeObjects/DataDoctrineSubject.php index bee6cfb..d1c2577 100644 --- a/tests/PatchManager/Handler/FakeObjects/DataDoctrineSubject.php +++ b/tests/PatchManager/Handler/FakeObjects/DataDoctrineSubject.php @@ -18,7 +18,6 @@ class DataDoctrineSubject implements Patchable /** * @param string $method - * @param array $args */ public function __call($method, array $args): void { diff --git a/tests/PatchManager/Handler/FakeObjects/DataSubject.php b/tests/PatchManager/Handler/FakeObjects/DataSubject.php index d2ad256..a1677ca 100644 --- a/tests/PatchManager/Handler/FakeObjects/DataSubject.php +++ b/tests/PatchManager/Handler/FakeObjects/DataSubject.php @@ -16,10 +16,6 @@ class DataSubject implements Patchable */ private $b; - /** - * @param string $method - * @param array $args - */ public function __call(string $method, array $args): void { if ('setB' === $method) { diff --git a/tests/PatchManager/Handler/FakeObjects/FiniteSubject.php b/tests/PatchManager/Handler/FakeObjects/FiniteSubject.php index 81200e6..b041ccb 100644 --- a/tests/PatchManager/Handler/FakeObjects/FiniteSubject.php +++ b/tests/PatchManager/Handler/FakeObjects/FiniteSubject.php @@ -7,9 +7,6 @@ class FiniteSubject implements StatefulInterface, Patchable { - /** - * @var string - */ private string $state; public function __construct() @@ -19,8 +16,6 @@ public function __construct() /** * Sets the object state - * - * @return string */ public function getFiniteState(): string { diff --git a/tests/PatchManager/Handler/FiniteHandlerTest.php b/tests/PatchManager/Handler/FiniteHandlerTest.php index d2a1ac8..1f5debd 100644 --- a/tests/PatchManager/Handler/FiniteHandlerTest.php +++ b/tests/PatchManager/Handler/FiniteHandlerTest.php @@ -15,14 +15,8 @@ class FiniteHandlerTest extends PatchManagerTestCase { - /** - * @var FiniteHandler - */ private FiniteHandler $handler; - /** - * @var StateMachine - */ private StateMachine $stateMachine; public function setUp(): void diff --git a/tests/PatchManager/OperationDataTest.php b/tests/PatchManager/OperationDataTest.php index 8277bc1..17dd397 100644 --- a/tests/PatchManager/OperationDataTest.php +++ b/tests/PatchManager/OperationDataTest.php @@ -1,9 +1,12 @@ 'data', 'test' => 1, 'test2' => '2']); $this->assertFalse($od->getData()->isEmpty()); - $this->assertInstanceOf('PhpCollection\Map', $od->getData()); $this->assertCount(2, $od->getData()); $this->assertContains('test', $od->getData()->keys()); $this->assertContains('test2', $od->getData()->keys()); @@ -43,18 +45,14 @@ public function testGetDataWithData(): void $this->assertSame('2', $od->getData()->get('test2')->getOrElse(null)); } - /** - * @dataProvider diffKeysProvider - * @param mixed $expected - * @param mixed $requiredKeys - */ - public function testDiffKeys($expected, $requiredKeys): void + #[DataProvider("diffKeysProvider")] + public function testDiffKeys(Sequence $expected, array $requiredKeys): void { $od = new OperationData(['op' => 'data', 'test' => 1, 'test2' => '2']); $this->assertEquals($expected, $od->diffKeys($requiredKeys)); } - public function diffKeysProvider(): array + public static function diffKeysProvider(): array { return [ [new Sequence(), ['test', 'test2']], diff --git a/tests/PatchManager/OperationMatcherTest.php b/tests/PatchManager/OperationMatcherTest.php index 94794f2..ab897fd 100644 --- a/tests/PatchManager/OperationMatcherTest.php +++ b/tests/PatchManager/OperationMatcherTest.php @@ -11,14 +11,8 @@ class OperationMatcherTest extends PatchManagerTestCase { - /** - * @var OperationMatcher - */ private OperationMatcher $matcher; - /** - * @var Sequence - */ private Sequence $ops; public function setUp(): void @@ -100,7 +94,6 @@ public function testHandlerThatRespondsFalseToCanHandle(): void /** * @param string $name - * @return \Closure */ private function handlerNameMatcher($name): \Closure { diff --git a/tests/PatchManager/PatchManagerTest.php b/tests/PatchManager/PatchManagerTest.php index fec32de..6680e23 100644 --- a/tests/PatchManager/PatchManagerTest.php +++ b/tests/PatchManager/PatchManagerTest.php @@ -4,7 +4,6 @@ use Cypress\PatchManager\Event\PatchManagerEvent; use Cypress\PatchManager\Exception\HandlerNotFoundException; -use Cypress\PatchManager\Handler\DataHandler; use Cypress\PatchManager\MatchedPatchOperation; use Cypress\PatchManager\OperationMatcher; use Cypress\PatchManager\PatchManager; @@ -12,7 +11,6 @@ use PhpCollection\Sequence; use Prophecy\Argument; use Symfony\Component\EventDispatcher\EventDispatcherInterface; -use Symfony\Component\OptionsResolver\Exception\MissingOptionsException; class PatchManagerTest extends PatchManagerTestCase { diff --git a/tests/PatchManager/PatchManagerTestCase.php b/tests/PatchManager/PatchManagerTestCase.php index 18aaa5a..3a70452 100644 --- a/tests/PatchManager/PatchManagerTestCase.php +++ b/tests/PatchManager/PatchManagerTestCase.php @@ -21,9 +21,6 @@ protected function tearDown(): void } /** - * @param null|string $name - * @param bool $canHandle - * * @return \Prophecy\Prophecy\ObjectProphecy */ protected function mockHandler(?string $name, bool $canHandle = true) @@ -41,7 +38,6 @@ protected function mockHandler(?string $name, bool $canHandle = true) /** * @param null $handlerName - * @return MatchedPatchOperation */ protected function getMatchedPatchOperation($handlerName = null): MatchedPatchOperation {