如何在Xampp中配置PhpUnit?
我已经在 Xampp 中成功安装了 PhpUnit,现在我需要配置它,我需要从文档中执行以下步骤:
2. Prepare the phpunit script:
1.
Rename the phpunit.php script to phpunit.
2.
Replace the @php_bin@ string in it with the path to your PHP command-line interpreter (usually /usr/bin/php).
3.
Copy it to a directory that is in your path and make it executable (chmod +x phpunit).
3. Prepare the PHPUnit/Util/PHP.php script:
1.
Replace the @php_bin@ string in it with the path to your PHP command-line interpreter (usually /usr/bin/php).
我在 PEAR 目录中找不到 phpunit.php。有关此文件在 PhpUnit 的 Xampp 安装中的位置的任何线索吗?有什么线索吗?
最好的问候,
Update1:
我已经通过 PEAR 安装了它。好的,我看看是否有效。
此致,
I have successfully installed PhpUnit in Xampp, now I need to configure it, i need to take this steps from the documentation:
2. Prepare the phpunit script:
1.
Rename the phpunit.php script to phpunit.
2.
Replace the @php_bin@ string in it with the path to your PHP command-line interpreter (usually /usr/bin/php).
3.
Copy it to a directory that is in your path and make it executable (chmod +x phpunit).
3. Prepare the PHPUnit/Util/PHP.php script:
1.
Replace the @php_bin@ string in it with the path to your PHP command-line interpreter (usually /usr/bin/php).
I can't find phpunit.php in the PEAR directory. Any clues on where is this file on a Xampp installation of PhpUnit? Any clues?
Best Regards,
Update1:
I have install it via PEAR. Ok, I will see if that work.
Best Regards,
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
你是怎么安装的?如果您使用 Xampp 附带的 pear 安装程序,它应该可以正常工作。
然后可执行文件应驻留在 /opt/lampp/bin/phpunit 中。
如果您以其他方式安装它(处理文件?抱歉,我在 xampp 文档中没有找到其他提示),那么只需将其指向我,我将编辑答案
How did you install it ? If you use the pear installer that is shipped with Xampp it should just work.
and the executable should then reside in /opt/lampp/bin/phpunit.
If you installed it in another way (coping the files ?, sry i didn't find other hints in the xampp docs) then just point me to it and i will edit the answer
我尝试对安装 phpunit 的所有必要/有用命令进行总结。我希望这仍然可以帮助一些偶然发现这一点的人。
请注意,最好以管理员身份运行所有命令。
祝你好运,
阳光明媚
I tried to make a summary of all necessary / useful commands to install phpunit. I hope this still might help some people, who stumble upon this.
Note that it is best, to run all commands as administrator.
Good Luck,
Sunny