Skip to content

[Testing] use the PHPUnit bridge to run tests #16626

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 21, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions testing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ After the library is installed, try running PHPUnit:

.. code-block:: terminal

$ php ./vendor/bin/phpunit
$ php bin/phpunit

This command automatically runs your application tests. Each test is a
PHP class ending with "Test" (e.g. ``BlogControllerTest``) that lives in
Expand Down Expand Up @@ -83,18 +83,18 @@ of your application for unit tests. So, if you're testing a class in the
Autoloading is automatically enabled via the ``vendor/autoload.php`` file
(as configured by default in the ``phpunit.xml.dist`` file).

You can run tests using the ``./vendor/bin/phpunit`` command:
You can run tests using the ``bin/phpunit`` command:

.. code-block:: terminal

# run all tests of the application
$ php ./vendor/bin/phpunit
$ php bin/phpunit

# run all tests in the Form/ directory
$ php ./vendor/bin/phpunit tests/Form
$ php bin/phpunit tests/Form

# run tests for the UserType class
$ php ./vendor/bin/phpunit tests/Form/UserTypeTest.php
$ php bin/phpunit tests/Form/UserTypeTest.php

.. tip::

Expand Down