File tree Expand file tree Collapse file tree 1 file changed +14
-0
lines changed Expand file tree Collapse file tree 1 file changed +14
-0
lines changed Original file line number Diff line number Diff line change @@ -240,4 +240,18 @@ guessers using the :method:`Symfony\\Component\\Form\\Test\\FormIntegrationTestC
240
240
and :method: `Symfony\\ Component\\ Form\\ Test\\ FormIntegrationTestCase::getTypeGuessers `
241
241
methods.
242
242
243
+ If you want to test the themes of your forms, you may want to make your test extends the
244
+ :class: `Symfony\\ Bridge\\ Twig\\ Test\\ FormLayoutTestCase ` class. This saves a lot of
245
+ boilerplate and code duplication by implementing the
246
+ :class: `Symfony\\ Component\\ Form\\ Test\\ FormIntegrationTestCase ` methods for you.
247
+ All that's left to do is to implement the
248
+ :method: `Symfony\\ Bridge\\ Twig\\ Test\\ FormLayoutTestCase::getTemplatePaths `, the
249
+ :method: `Symfony\\ Bridge\\ Twig\\ Test\\ FormLayoutTestCase::getTwigExtensions ` and
250
+ the :method: `Symfony\\ Bridge\\ Twig\\ Test\\ FormLayoutTestCase::getThemes ` methods.
251
+
252
+ .. versionadded :: 6.4
253
+
254
+ The :class: `Symfony\\ Bridge\\ Twig\\ Test\\ FormLayoutTestCase ` class was
255
+ introduced in Symfony 6.4.
256
+
243
257
.. _`PHPUnit data providers` : https://docs.phpunit.de/en/9.6/writing-tests-for-phpunit.html#data-providers
You can’t perform that action at this time.
0 commit comments