Releases: kenjis/ci-phpunit-test
Releases · kenjis/ci-phpunit-test
v0.14.0
Upgrade Note for PHPUnit 6.0 users
- Please update
application/tests/phpunit.xml. Replace it or apply this patch.
Added
- download_helper for testing.
$this->newModel()for model unit testing. See #156.$this->newLibrary()for library unit testing. See #161.- Now you can write test code for file uploading in controller testing. See #157.
- Now Monkey Patching supports PHP 7.1 new syntax.
Fixed
- Fix bug that
include_pathsand/orexclude_pathsin Monkey Patching may not work correctly on Windows.
Others
- Compatible with CodeIgniter 3.1.3
- Update nikic/PHP-Parser to v2.1.1
- Add nikic/PHP-Parser v3.0.3
- Compatible with PHPUnit 6.0
v0.13.0
Upgrade Note
- If you use database test helpers, please install
tests/DbTestCase.phpmanually.
Added
- Database test helpers. See #133.
- Now you can return Closure with
$this->getDouble(). See Function/Class Reference. - Now you can set constructor params with
$this->getDouble(). See #130. $this->newController()for controller unit testing. See #147.
Fixed
- Fix bug that routes with closure cause serialization errors. See #139.
Others
- Compatible with CodeIgniter 3.1.2
v0.12.2
v0.12.1
v0.12.0
Added
- Monkey Patching on constants. See How to Write Tests.
Others
- Update nikic/PHP-Parser to v2.0.1
v0.11.3
v0.11.2
v0.11.1
Fixed
- Fix bug that
$this->input->get_request_header()returns the first header value for all tests. See #92. - Fix bug that config values are not reset between tests. See #94.
- Fix bug that
CI_Output::_display()is called even if you call a controller method directly (when you pass an array to the 2nd argument of$this->request()).
Others
- Improved documentation for
$this->request().
v0.11.0
Upgrade Note
- Now ci-phpunit-test replaces
CI_Input. If you use MY_Input, see How to Write Tests. - If you use Monkey Patching, please update
tests/Bootstrap.php. See How to Write Tests. - If you use PsySH v0.5, please update to v0.6.
Added
$this->assertResponseCookie()to assert HTTP response cookies. See #88.- Now
$this->request->enableHooks()calls hookdisplay_override. $this->request->addCallablePreConstructor()to add callable.- Now Moneky Patching can patch code with PHP 7 new syntax.
header()andsetcookie()are added to Function Patcher's white list.
Fixed
_output()method in controllers does not work in controller testing.
Others
- Compatible with CodeIgniter 3.0.4
- Update nikic/PHP-Parser to v2.0.0