/
Step 1: Unit testing
Step 1: Unit testing
Innomatic supports unit testing with PHPUnit and provides a preconfigured phpunit.xml configuration file.
Applications can add PHPUnit tests using the unittest component.
Test files should be added inside a tests subdirectory inside the tested class folder:
innomatic/core/classes/innomatic/core/InnomaticSettings.php innomatic/core/classes/innomatic/core/tests/InnomaticSettingsTest.php
Example definition in application.xml file:
<class name="innomatic/core/InnomaticSettings.php" /> <unittest name="innomatic/core/tests/InnomaticSettingsTest.php" />
To test Innomatic code, PHPUnit must be launched inside the “innomatic” directory of an installed Innomatic instance:
cd innomatic phpunit
Limitations
Innomatic applications to be tested must be deployed inside a working Innomatic installation before running the test suite (you cannot run the tests inside the sources folder).
Please note that as of Innomatic 6.4.x unit testing support is experimental; there are no such facilities like automatic generation of test databases, etc.
, multiple selections available,
Related content
Running tests
Running tests
More like this
Step 3: Innomatic debugging mode and Innocoder Debugger
Step 3: Innomatic debugging mode and Innocoder Debugger
More like this
Unit Test component
Unit Test component
More like this
Step 2: Profiling
Step 2: Profiling
More like this
Beginner Tutorial
Beginner Tutorial
More like this
Step 1: Logs
Step 1: Logs
More like this