您好,欢迎来到三六零分类信息网!老站,搜索引擎当天收录,欢迎发信息

phpunit 装配

2025/12/26 15:13:29发布13次查看
phpunit 安装
详细的安装步骤看官方文档,这里主要介绍遇到的问题。
为了生成分析报告:安装了 xdebug
wget http://phar.phpunit.de/phpunit.phar
chmod +x phpunit.phar
mv phpunit.phar /usr/local/bin/phpunit/
查看是否安装成功
/php5/bin/php phpunit.phar --version
这里操作时报错了。说没有 gmp.soa 文件。
我建了个软链接文件 gmp.soa => gmp.so
解决掉。
这里显示:
phpunit 4.6.4 by sebastian bergmann and contributors.
表示安装成功了。
下面写个测试示例:
====================
# cat dependencyfailuretest.php
marktestincomplete(this is don't done test.); } public function testtwo() { }}
====================
执行代码
/php5/bin/php phpunit.phar /tmp/dependencyfailuretest
phpunit 4.6.4 by sebastian bergmann and contributors.
i.
time: 1.15 seconds, memory: 22.75mb
ok, but incomplete, skipped, or risky tests!
tests: 2, assertions: 0, incomplete: 1.
#
注意执行时的文件路径不可以有下划线。
该用户其它信息

VIP推荐

免费发布信息,免费发布B2B信息网站平台 - 三六零分类信息网 沪ICP备09012988号-2
企业名录 Product