Skip to content

Commit f7d59f7

Browse files
committed
Dont mention PHPUnit bridge
1 parent 78c2531 commit f7d59f7

File tree

1 file changed

+8
-15
lines changed

1 file changed

+8
-15
lines changed

testing.rst

Lines changed: 8 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -15,35 +15,29 @@ Symfony integrates with an independent library called `PHPUnit`_ to give you a
1515
rich testing framework. This article won't cover PHPUnit itself, which has its
1616
own excellent `documentation`_.
1717

18-
Before creating your first test, install the `PHPUnit Bridge component`_, which
19-
wraps the original PHPUnit binary to provide additional features:
18+
Before creating your first test, install the PHPUnit with the following command:
2019

2120
.. code-block:: terminal
2221
23-
$ composer require --dev symfony/phpunit-bridge
22+
$ composer require --dev phpunit/phpunit
2423
25-
After the library downloads, try executing PHPUnit by running (the first time
26-
you run this, it will download PHPUnit itself and make its classes available in
27-
your app):
24+
After the library is installed, try executing PHPUnit by running:
2825

2926
.. code-block:: terminal
3027
31-
$ ./bin/phpunit
28+
$ ./vendor/bin/phpunit
3229
3330
.. note::
3431

35-
The ``./bin/phpunit`` command is created by :ref:`Symfony Flex <symfony-flex>`
36-
when installing the ``phpunit-bridge`` package. If the command is missing, you
37-
can remove the package (``composer remove symfony/phpunit-bridge``) and install
38-
it again. Another solution is to remove the project's ``symfony.lock`` file and
39-
run ``composer install`` to force the execution of all Symfony Flex recipes.
32+
:ref:`Symfony Flex <symfony-flex>` has automatically created ``phpunit.xml.dist``
33+
and ``tests/bootstrap.php``. If the files are missing, you can remove the package
34+
(``composer remove phpunit/phpunit``) and install it again.
4035

4136
Each test is a PHP class that should live in the ``tests/`` directory of
4237
your application. If you follow this rule, then you can run all of your
4338
application's tests with the same command as before.
4439

45-
PHPUnit is configured by the ``phpunit.xml.dist`` file in the root of your
46-
Symfony application.
40+
PHPUnit is configured by the ``phpunit.xml.dist`` file in the root of your application.
4741

4842
.. tip::
4943

@@ -1030,7 +1024,6 @@ Learn more
10301024

10311025
.. _`PHPUnit`: https://phpunit.de/
10321026
.. _`documentation`: https://phpunit.readthedocs.io/
1033-
.. _`PHPUnit Bridge component`: https://symfony.com/components/PHPUnit%20Bridge
10341027
.. _`Writing Tests for PHPUnit`: https://phpunit.readthedocs.io/en/stable/writing-tests-for-phpunit.html
10351028
.. _`unit test`: https://en.wikipedia.org/wiki/Unit_testing
10361029
.. _`$_SERVER`: https://www.php.net/manual/en/reserved.variables.server.php

0 commit comments

Comments
 (0)