HowTo create a Test Case Class from a PHP Class¶
To create a Test Case from a PHP Class follow these steps:
1. First you have to configure PHPUnit.
2. Right click on the PHP Class on PHP Explorer and select New -> PHPUnit Test Case.
[Image context menu]
If this option is missing you can also click on Other... and select PHP -> PHPUnit -> PHPUnit Test Case. To activate the shortcuts you have to reset your perspective (Window -> Reset Perspectoive...).
[Image file new dialog]
3. Now you should see the prefilled wizard page. If the target file already exists all missing test methods will be supplemented.
[Image wizard page]