Page 1 of 1

cakephp simpletest to use phpundercontrol like phpunit

Posted: Sun Jul 19, 2009 2:23 pm
by jmut
Hi.
Currently we have a project that is using cakephp framework for one reason or another. As cakephp is integretaed with simpletest we have all our tests implemented like so. Lately I am reading on continuous integration and stuff and got stuck with phpundercontrol But seems it's more well integrated with phpunit.

Has anyone used it with simpletest or perhaps some easy simpletest to phpunit transition.

Any pointers are more than welcome.

Re: cakephp simpletest to use phpundercontrol like phpunit

Posted: Sat Aug 08, 2009 12:55 pm
by josh
The biggest issue is the paramater orders for expected and actual are reversed,

assertEquals stays the same

in simpletest assertReference gets changed to assertSame for phpunit, any places you are using simpletests assert method assertSame needs to be changed to assertIdentical

Creating mock objects is different if you use constructor signatures, if you have your tests well factored it wont be as big of a pain tho