Skip to content

Add best practice note about version #9700

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

Closed
wants to merge 4 commits into from
Closed
Changes from 1 commit
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
6 changes: 6 additions & 0 deletions components/phpunit_bridge.rst
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,12 @@ Alternatively, you can clone the `<https://github.com/symfony/phpunit-bridge>`_

.. include:: /components/require_autoload.rst.inc


.. best-practice::

PHPUnit Bridge is designed to remain compatible with Symfony version 2.7 up to master,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure we should tell about 2.7: it's being EOLed in a few weeks. Maybe something like that instead?

The PHPUnit bridge is designed to work with all maintained versions of Symfony components, even across different major versions of them. You should always use its very latest stable major version to get the most accurate deprecation reports.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe also, the line above "$ composer require --dev symfony/phpunit-bridge" should be updated to
$ composer require --dev "symfony/phpunit-bridge:*"

so be sure to install and run the latest version.

If you plan to :ref:`write-assertions-about-deprecations` and use the regular
PHPUnit script (not the modified PHPUnit script provided by Symfony), you have
to register a new `test listener`_ called ``SymfonyTestsListener``:
Expand Down