From ba19a535ea96d623e17ed4821a197652353ee4cf Mon Sep 17 00:00:00 2001 From: Antoine Lamirault Date: Fri, 13 Jan 2023 20:32:14 +0100 Subject: [PATCH] Enable argument_variable_must_match_type doctor-rst rule --- .doctor-rst.yaml | 5 ++++- components/uid.rst | 2 +- security/entry_point.rst | 2 +- serializer.rst | 2 +- templating/global_variables.rst | 2 +- 5 files changed, 8 insertions(+), 5 deletions(-) diff --git a/.doctor-rst.yaml b/.doctor-rst.yaml index 1afa4342584..f8a111cf2c6 100644 --- a/.doctor-rst.yaml +++ b/.doctor-rst.yaml @@ -1,5 +1,9 @@ rules: american_english: ~ + argument_variable_must_match_type: + arguments: + - { type: 'ContainerBuilder', name: 'containerBuilder' } + - { type: 'ContainerConfigurator', name: 'containerConfigurator' } avoid_repetetive_words: ~ blank_line_after_anchor: ~ blank_line_after_directive: ~ @@ -96,6 +100,5 @@ whitelist: - '.. versionadded:: 3.6' # MonologBundle - '// bin/console' - 'End to End Tests (E2E)' - - '.. code-block:: php' - '.. _`a feature to test applications using Mercure`: https://github.com/symfony/panther#creating-isolated-browsers-to-test-apps-using-mercure-or-websocket' - '.. End to End Tests (E2E)' diff --git a/components/uid.rst b/components/uid.rst index cf17b237f19..caac3034429 100644 --- a/components/uid.rst +++ b/components/uid.rst @@ -132,7 +132,7 @@ configure the behavior of the factory using configuration files:: namespace Symfony\Component\DependencyInjection\Loader\Configurator; - return static function (ContainerConfigurator $configurator): void { + return static function (ContainerConfigurator $containerConfigurator): void { $services = $configurator->services() ->defaults() ->autowire() diff --git a/security/entry_point.rst b/security/entry_point.rst index daee51493fa..42fb6452b71 100644 --- a/security/entry_point.rst +++ b/security/entry_point.rst @@ -61,8 +61,8 @@ You can configure this using the ``entry_point`` setting: .. code-block:: php // config/packages/security.php - use Symfony\Config\SecurityConfig; use App\Security\SocialConnectAuthenticator; + use Symfony\Config\SecurityConfig; return static function (SecurityConfig $security) { $security->enableAuthenticatorManager(true); diff --git a/serializer.rst b/serializer.rst index ee31efa0b12..0a1409de2b5 100644 --- a/serializer.rst +++ b/serializer.rst @@ -156,8 +156,8 @@ configuration: .. code-block:: php // config/packages/framework.php - use Symfony\Config\FrameworkConfig; use Symfony\Component\Serializer\Normalizer\AbstractObjectNormalizer; + use Symfony\Config\FrameworkConfig; return static function (FrameworkConfig $framework) { $framework->serializer() diff --git a/templating/global_variables.rst b/templating/global_variables.rst index c7bfec3049c..f38d06aca02 100644 --- a/templating/global_variables.rst +++ b/templating/global_variables.rst @@ -99,8 +99,8 @@ the ``@`` character, which is the usual syntax to .. code-block:: php // config/packages/twig.php - use Symfony\Config\TwigConfig; use function Symfony\Component\DependencyInjection\Loader\Configurator\service; + use Symfony\Config\TwigConfig; return static function (TwigConfig $twig) { // ...