Skip to content
Snippets Groups Projects
Commit 8a7fc19c authored by sarvesh21's avatar sarvesh21
Browse files

added testing documentation

parent 745a88bc
No related branches found
No related tags found
No related merge requests found
......@@ -29,6 +29,7 @@ The extension is licensed under [AGPL-3.0](LICENSE.txt).
* [Add your own data source for a CiviCRM Entity](docs/add_your_own_datasource.md)
* Add your own data source for a CSV File
* How to store a data processor in code in your extension
* [Develop PHPUnit TestCase for the extension](docs/how_to_create_test.md)
## Installation
......
# How to create a PHPUnit Test
- Create file with appropriate name ending with test. For Example `CreateDataProcessorTest.php`
- Follow the simplest test case file `CreateDataProcessorTest.php` for creating a test case.
- Create a function whose name starting with test. For Example `testCreateDataProcessor`. All the function starting with **test** will be evaluated, so name your utility functions properly.
- If you want to reset the Test Database and install from beginning pass `True` in `apply()` function in `setupHeadless() function`.
- Don't remove `setUp()` and `tearDown()` function from the UnitTest file.
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment