我在 win 7 中使用 wamp 2.2 并尝试安装 phpunit
1.我从https://github.com/sebastianbergmann/phpunit下载 phpunit-master.zip 。2.我解压。3.我把它放在D:\wamp\bin\php\php5.3.10下,然后,我在php脚本下面运行;
<?php
//testsuite.wordcount.php
require_once 'PHPUnit/TextUI/TestRunner.php';
require_once "PHPUnit/Framework/TestSuite.php";
require_once "class.testwordcount.php";
$suite = new PHPUnit_Framework_TestSuite();
$suite->addTestSuite("TestWordCount");
PHPUnit_TextUI_TestRunner::run($suite);
?>
输出为: *Warning: require_once(PHPUnit/TextUI/TestRunner.php) [function.require-once]: failed to open stream: No such file or directory in D:\wamp\www\oop\test.php on line 4*
看来我没有正确安装phpunit,所以可能出了什么问题?