I’m currently trying to get PHPUnit working with together with Magento. On some places in the web people recommend the extension from EcomDev so I tried it out.
I build an example setup like written in this tutorial, I just replaced EcomDev_Example_… with Test_JustTest_…
However, it doesn’t work as it should and I guess I put the data in the wrong config.xml. At the moment I’ve written down the module name in /app/code/local/Test/JustTest/etc/config.xml and in the config.xml of the extension to just try something different. Well, I can run PHPUnit but it always tells me that there’s no test to run.
I spent a lot of time on Google not finding a more detailed example
Im faced with the same problem, but now I get it worked.
I created app/code/local/Namespace/Module/etc/config.xml with:
In fact the name of these are not Namespace_Module, I just replaced to show you. Its a module that overrides numeric model from magento, but it has no big differences.
See that my test is under
app/code/local/Namespace/Module/Test/Model/Entity/Increment/Numeric.php
And looks like:
After all set, you should run your tests using the following command on console/terminal:
Remember that you should enable your module by adding Namespace_Module.xml at app/etc/modules as any other model. My mistake was that i named the folder as Tests instead of Test in my model. I dont think you are doing the same thing…
Anyway, I hope it helps. For more information, the manual could help you a lot.