Task #104799
closedLet ExtensionScanner recognize implementations of deprecated/removed abstract/interface method definitions
100%
Description
The Extension Scanner of the EXT:install module allows to scan
custom extensions based on several static code analysis rules.
Most of these rules depend on analyzing code to see if deprecated
or removed methods are called, or if argument names change,
annotations/attributes get removed and so on.
This patch adds a MethodDefinitionMatcher
matcher which
can analyze definitions that need to be migrated.
A good example for this is a change in Fluid ViewHelpers deprecating
the renderStatic
method.
Because ViewHelpers themself do not execute a renderStatic
method, any custom ViewHelper implementing renderStatic
would not be revealed in the Extension Scanner before.
The Matcher receives a configuration like:
return [ 'TYPO3Fluid\Fluid\Core\ViewHelper\AbstractViewHelper::renderStatic' => [ 'restFiles' => [ 'Breaking-82162-GlobalErrorConstantsRemoved.rst', ], ], ];
and based on this, iterates every custom code to check if
any class inherits from this TYPO3Fluid\Fluid\Core\ViewHelper\AbstractViewHelper
abstract,
and then checks for a given method name (here renderStatic
).
These matches will be reported as strong matches.
Files