Skip to content

Commit c070711

Browse files
committed
[Console] Mention that CommandTester doesn't dispatch console events
1 parent 077ab13 commit c070711

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

console.rst

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -306,6 +306,12 @@ console::
306306
You can also test a whole console application by using
307307
:class:`Symfony\\Component\\Console\\Tester\\ApplicationTester`.
308308

309+
.. caution::
310+
311+
When testing commands using the ``CommandTester`` class, console events are
312+
not dispatched. If you need to test those events, use the
313+
:class:`Symfony\\Component\\Console\\Tester\\ApplicationTester` instead.
314+
309315
.. note::
310316

311317
When using the Console component in a standalone project, use

0 commit comments

Comments
 (0)