Skip to content

Commit

Permalink
minor #5654 Doc about new way of running tests (nicolas-grekas)
Browse files Browse the repository at this point in the history
This PR was merged into the 2.3 branch.

Discussion
----------

Doc about new way of running tests

| Q             | A
| ------------- | ---
| Doc fix?      | yes
| New docs?     | yes
| Applies to    | all
| Fixed tickets | -

Related to symfony/symfony#15575

Commits
-------

dc754c8 Doc about new way of running tests
  • Loading branch information
xabbuh committed Sep 8, 2015
2 parents 05c57e3 + dc754c8 commit e037910
Showing 1 changed file with 13 additions and 8 deletions.
21 changes: 13 additions & 8 deletions contributing/code/tests.rst
Original file line number Diff line number Diff line change
Expand Up @@ -16,14 +16,13 @@ In any case, it's a good practice to run tests locally before submitting a
Before Running the Tests
------------------------

To run the Symfony test suite, `install PHPUnit`_ 4.2 (or later) first. Then,
install the external dependencies used during the tests, such as Doctrine, Twig
and Monolog. To do so, :doc:`install Composer </cookbook/composer>` and execute
the following:
To run the Symfony test suite, install the external dependencies used during the
tests, such as Doctrine, Twig and Monolog. To do so,
:doc:`install Composer </cookbook/composer>` and execute the following:

.. code-block:: bash
$ composer install
$ composer update
.. _running:

Expand All @@ -35,7 +34,7 @@ command:

.. code-block:: bash
$ phpunit
$ php ./phpunit symfony
The output should display ``OK``. If not, read the reported errors to figure out
what's going on and if the tests are broken because of the new code.
Expand All @@ -48,6 +47,12 @@ what's going on and if the tests are broken because of the new code.

.. code-block:: bash
$ phpunit src/Symfony/Component/Finder/
$ php ./phpunit src/Symfony/Component/Finder/
.. _`install PHPUnit`: https://phpunit.de/manual/current/en/installation.html
.. tip::

On Windows, install the `ConEmu`_ or `ANSICON`_ free applications to see
colored test results.

.. _ConEmu: https://code.google.com/p/conemu-maximus5/
.. _ANSICON: https://github.com/adoxa/ansicon/releases

0 comments on commit e037910

Please sign in to comment.