Skip to content
Merged
Show file tree
Hide file tree
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
11 changes: 11 additions & 0 deletions en/appendices/3-4-migration-guide.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@
CakePHP 3.4 is an API compatible upgrade from 3.3. This page outlines the
changes and improvements made in 3.4.

Minimum PHP 5.6 Required
Copy link
Member

Choose a reason for hiding this comment

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

========================
CakePHP 3.4 requires at least PHP 5.6.0 as PHP 5.5 is no longer supported and
won't receive any security fixes anymore.

Deprecations
============

Expand Down Expand Up @@ -449,3 +454,9 @@ PluginShell

* ``cake plugin load`` and ``cake plugin unload`` now support a ``--cli``
option, which updates the ``bootstrap_cli.php`` instead.

TestSuite
=========

* Support to ``PHPUnit 6`` was added. With this framework version requiring PHP
5.6.0 as a minimum version, the supported version of PHPUnit are now ``^5.7|^6.0``
2 changes: 1 addition & 1 deletion en/contributing/code.rst
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ setup. You'll need the following software:

* Git
* PHP |minphpversion| or greater
* PHPUnit 3.7.0 or greater
* PHPUnit 5.7.0 or greater
Copy link
Member

Choose a reason for hiding this comment

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

😼


Set up your user information with your name/handle and working email address::

Expand Down
10 changes: 9 additions & 1 deletion en/development/testing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@ To install PHPUnit with Composer:

.. code-block:: bash

$ php composer.phar require --dev phpunit/phpunit:"^5.7|^6.0"
Copy link
Member

Choose a reason for hiding this comment

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

Copy link
Member

Choose a reason for hiding this comment

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

No because the change is on master..


// Before CakePHP 3.4.1
$ php composer.phar require --dev phpunit/phpunit:"<6.0"

This will add the dependency to the ``require-dev`` section of your
Expand Down Expand Up @@ -124,13 +127,18 @@ tests:
#. The filenames of these files should end in **Test.php** instead
of just .php.
#. The classes containing tests should extend ``Cake\TestSuite\TestCase``,
``Cake\TestSuite\IntegrationTestCase`` or ``\PHPUnit_Framework_TestCase``.
``Cake\TestSuite\IntegrationTestCase`` or ``\PHPUnit\Framework\TestCase``.
#. Like other classnames, the test case classnames should match the filename.
**RouterTest.php** should contain ``class RouterTest extends TestCase``.
#. The name of any method containing a test (i.e. containing an
assertion) should begin with ``test``, as in ``testPublished()``.
You can also use the ``@test`` annotation to mark methods as test methods.

.. versionadded:: 3.4.1
Support for PHPUnit 6 was addded. If you're using a PHPUnit version lower
than 5.7.0, your tests classes should either extends Cake's classes or
``PHPUnit_Framework_TestCase``.

Creating Your First Test Case
=============================

Expand Down