我一直在寻找一个教程,帮助我将PHPUnit与CakePHP集成。寻找使用Selenium测试太喜欢PHPUnit。
我一直尝试按照 http ://cakebaker.42dh/2006/03/22/selenium/ 但似乎没有得到它的工作。
解决方案不幸的是CakePHP不是设计为与PHPUnit一起工作。 CakePHP已切换到使用 SimpleTest ,您将有两个选择之一,重构测试以使用SimpleTest或修改核心以使用PHPUnit。
但是,应该说明 Mark Story指出,CakePHP 2.0将使用PHPUnit 来测试框架,所以如果你可以等到那时候可能会成为最好的选择。
CakePHP 1.3测试书
I have been looking for a tutorial to help me integrate PHPUnit with CakePHP. Looking to use Selenium tests too so prefer PHPUnit.
I have been trying to follow the tutorial on cakebaker.42dh/2006/03/22/selenium/ but cant seem to get it work. Any good tutorials out there?
Thanks!
解决方案Unfortunately CakePHP isn't designed to work together with PHPUnit. CakePHP has switched to using SimpleTest and you'll have one of two choices, refactor your tests to work with SimpleTest or modify the core to use PHPUnit.
However it should be stated that Mark Story has stated that CakePHP 2.0 will use PHPUnit for it's testing framework, so if you can aford to wait till then that may wind up being the best option.
CakePHP 1.3 Book on Testing
更多推荐
将PHPUnit与CakePHP 1.3集成
发布评论