如何检查我的函数打印/回声是否为某种东西?
我经常使用echo来调试函数代码:
public function MyFunc() {
// some code...
echo "OK";
// some code...
}
如何检查我的函数打印/回声是否为某物?
(伪代码):
MyFunc();
if (<when something was printed>){
echo "You forgot to delete echo calls in this function";
}