This is probably a really easy one, but I can’t seem to find the answer.
I have written some custom assert functions for unit testing my models. I would like these functions to be available in all of my unit tests, no matter the model. Where would I put these so that they are available to every unit test?
I use MyCakeTestCase which extends the CakeTestCase.
There I can put all my custom methods.
see this test for example:
https://github.com/dereuromark/tools/blob/2.0/Test/Case/Lib/CaptchaLibTest.php
just put your own test case in your lib folder (either app or – as I prefer – plugin):
and either lib or pluginlib uses statement: