Download the PHP package nueip/codeigniter-phpunit without Composer
On this page you can find all versions of the php package nueip/codeigniter-phpunit. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download nueip/codeigniter-phpunit
More information about nueip/codeigniter-phpunit
Files in nueip/codeigniter-phpunit
Package codeigniter-phpunit
Short Description CodeIgniter 3 PHPUnit Test extension library
License MIT
Homepage https://github.com/nueip/codeigniter-phpunit
Informations about the package codeigniter-phpunit
CodeIgniter PHPUnit Test
CodeIgniter 3 PHPUnit Test extension library
This RESTful API extension is collected into nueip/codeigniter-pack which is a complete solution for Codeigniter framework.
FEATURES
-
PHPUnit Test in Codeigniter 3 Framework
- Easy to install into your Codeigniter project by Composer
OUTLINE
- FEATURES
- OUTLINE
- REQUIREMENTS
- INSTALLATION
- DIRECTORY STRUCTURE
- CONFIGURATION
- USAGE
- TEST CASE
REQUIREMENTS
This library requires the following:
- PHP 5.3.0+
- CodeIgniter 3.0.0+
INSTALLATION
Run Composer in your Codeigniter project under the folder \application
:
composer require nueip/codeigniter-phpunit
DIRECTORY STRUCTURE
CONFIGURATION
According to Directory Structure, create and configure phpunit.xml
under application
directory:
For this phpunit.xml
template, the test cases directory is application/test
, make sure you would create every test cases under it.
USAGE
In the application
directory of this library, run phpunit
from vendor:
Or using absolute path commands like:
Then the result would like:
TEST CASE
With this extension libaray, you could write test cases with loading Codeigniter framework.
For example, write a test case application/tests/CodeigniterTest.php
for testing Codeigniter config component:
Then you would get the result OK (1 test, 1 assertion)
by running PHPUnit test.