开发者

Having trouble understanding what files to include to make PHPUnit work properly

I'm trying to get started with unit testing and PHPUnit. I see code here that indicates the w开发者_高级运维ay to get started is to include 'PHPUnit/Framework.php' and then create a test case that extends PHPUnit_Framework_TestCase

It looks like that's no longer the way to include PHPUnit but the new docs don't explain what files needed to be included to make PHPUnit work.

What am I missing? When I include 'Framework.php' an error is triggered that tells me no to include that file any longer. 'Autoloader.php' does not work either. When I include files such as 'TestSuiteLoader.php' and others I'll inevitably run into an error that tells me another needed file is missing. I doubt I'm supposed to manually include dozens of files but the docs aren't clear on what I should include yet.


You should include the phpunit library in your php.ini's include_path rather including them manually.

My include path is include_path = ".;C:\wamp\library\phpunit";

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜