Skip to content

Commit 5ce06d0

Browse files
committed
Merge branch '7.3' into 7.4
* 7.3: Update DOCtor-RST and enable new rules
2 parents c9d577b + 1839b69 commit 5ce06d0

File tree

12 files changed

+33
-20
lines changed

12 files changed

+33
-20
lines changed

.doctor-rst.yaml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,17 @@ rules:
2121
ensure_order_of_code_blocks_in_configuration_block: ~
2222
ensure_php_reference_syntax: ~
2323
extend_abstract_controller: ~
24+
filepath_and_namespace_should_match:
25+
namespace_mapping:
26+
'src/': 'App\'
27+
'tests/': 'App\Tests\'
28+
ignored_namespaces:
29+
- '/^Acme/'
30+
- '/^Shared/'
31+
ignored_paths:
32+
- '/^config\//'
33+
- '/^example\.com\//'
34+
- '/^apps\/api\/tests\//'
2435
# extension_xlf_instead_of_xliff: ~
2536
forbidden_directives:
2637
directives:
@@ -43,12 +54,14 @@ rules:
4354
no_composer_req: ~
4455
no_directive_after_shorthand: ~
4556
no_duplicate_use_statements: ~
57+
no_empty_directive: ~
4658
no_empty_literals: ~
4759
no_explicit_use_of_code_block_php: ~
4860
no_footnotes: ~
4961
no_inheritdoc: ~
5062
no_merge_conflict: ~
5163
no_namespace_after_use_statements: ~
64+
no_non_breaking_space: ~
5265
no_php_open_tag_in_code_block_php_directive: ~
5366
no_space_before_self_xml_closing_tag: ~
5467
no_typographic_quotes: ~

.github/workflows/ci.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ jobs:
7272
key: ${{ runner.os }}-doctor-rst-${{ steps.extract_base_branch.outputs.branch }}
7373

7474
- name: "Run DOCtor-RST"
75-
uses: docker://oskarstark/doctor-rst:1.73.0
75+
uses: docker://oskarstark/doctor-rst:1.76.0
7676
with:
7777
args: --short --error-format=github --cache-file=/github/workspace/.cache/doctor-rst.cache
7878

bundles/prepend_extension.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ on another bundle being loaded as well.
2020
To give an Extension the power to do this, it needs to implement
2121
:class:`Symfony\\Component\\DependencyInjection\\Extension\\PrependExtensionInterface`::
2222

23-
// src/Acme/HelloBundle/DependencyInjection/AcmeHelloExtension.php
23+
// src/DependencyInjection/AcmeHelloExtension.php
2424
namespace Acme\HelloBundle\DependencyInjection;
2525

2626
use Symfony\Component\DependencyInjection\ContainerBuilder;

components/phpunit_bridge.rst

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -138,12 +138,12 @@ a directory containing multiple test suites with their own ``phpunit.xml.dist``.
138138
.. code-block:: terminal
139139
140140
├── tests/
141-
   ├── Functional/
142-
   │   ├── ...
143-
   │   └── phpunit.xml.dist
144-
   ├── Unit/
145-
   │   ├── ...
146-
   │   └── phpunit.xml.dist
141+
├── Functional/
142+
├── ...
143+
└── phpunit.xml.dist
144+
├── Unit/
145+
├── ...
146+
└── phpunit.xml.dist
147147
148148
.. code-block:: terminal
149149

console/style.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -488,7 +488,7 @@ your commands. Thanks to the ``StyleInterface`` you won't need to change the cod
488488
of your commands to change their appearance::
489489

490490
// src/Command/MyCommand.php
491-
namespace App\Console;
491+
namespace App\Command;
492492

493493
use App\Console\CustomStyle;
494494
use Symfony\Component\Console\Command\Command;

contributing/documentation/standards.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ Example
101101
.. code-block:: php
102102
103103
// src/Foo/Bar.php
104-
namespace Foo;
104+
namespace App\Foo;
105105
106106
use Acme\Demo\Cat;
107107
// ...

mercure.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -635,7 +635,7 @@ During unit testing it's usually not needed to send updates to Mercure.
635635

636636
You can instead make use of the ``MockHub`` class::
637637

638-
// tests/FunctionalTest.php
638+
// tests/Unit/Controller/FunctionalTest.php
639639
namespace App\Tests\Unit\Controller;
640640

641641
use App\Controller\MessageController;

reference/constraints/Choice.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ If your valid choice list is simple, you can pass them in directly via the
8686
8787
.. code-block:: php
8888
89-
// src/EntityAuthor.php
89+
// src/Entity/Author.php
9090
namespace App\Entity;
9191
9292
use Symfony\Component\Validator\Constraints as Assert;
@@ -179,7 +179,7 @@ constraint.
179179
180180
.. code-block:: php
181181
182-
// src/EntityAuthor.php
182+
// src/Entity/Author.php
183183
namespace App\Entity;
184184
185185
use Symfony\Component\Validator\Constraints as Assert;

reference/constraints/Compound.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ You can now use it anywhere you need it:
5353
.. code-block:: php-attributes
5454
5555
// src/Entity/User.php
56-
namespace App\Entity\User;
56+
namespace App\Entity;
5757
5858
use App\Validator\Constraints as Assert;
5959
@@ -89,7 +89,7 @@ You can now use it anywhere you need it:
8989
.. code-block:: php
9090
9191
// src/Entity/User.php
92-
namespace App\Entity\User;
92+
namespace App\Entity;
9393
9494
use App\Validator\Constraints as Assert;
9595
use Symfony\Component\Validator\Mapping\ClassMetadata;

security.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1897,7 +1897,7 @@ You can logout user programmatically using the ``logout()`` method of the
18971897
:class:`Symfony\\Bundle\\SecurityBundle\\Security` helper::
18981898

18991899
// src/Controller/SecurityController.php
1900-
namespace App\Controller\SecurityController;
1900+
namespace App\Controller;
19011901

19021902
use Symfony\Bundle\SecurityBundle\Security;
19031903

0 commit comments

Comments
 (0)