joomla-rad
joomla-rad copied to clipboard
[Doc] How to run Unittest
This instruction should be write to a standard document later
Test Environment
Joomla test bootstrap https://github.com/joomla/joomla-cms/blob/staging/tests/unit/bootstrap.php
Clone a Test Windwalker package
$ composer create-project windwalker/joomla-rad libraries/windwalker dev-staging
...
Do you want to remove the existing VCS (.git, .svn..) history? [Y,n]? n
$ cd libraries/windwalker
$ git remote add {your_remote} [email protected]:smstw/windwalker-joomla-rad.git
$ git fetch {your_remote} dev-2.1:dev-2.1
$ git checkout dev-2.1
$ composer install
Test Class
Use this command to geneate Test Classes
php bin/windwalker generator test <Folder> <Class>
For example
php bin/windwalker generator test Helper ModalHelper
It will generate a test class in test/Helper/ModalHelper
https://github.com/smstw/windwalker-joomla-rad/issues/14