phpunit破坏了我的数组差异输出,如何获得完整信息?
这很烦人:phpunit破坏了我的数组差异输出,如何获得完整信息?,php,arrays,phpunit,Php,Arrays,Phpunit,这很烦人: Failed asserting that two arrays are equal. --- Expected +++ Actual @@ @@ Array ( + 0 => 'Argument $name does match typ...string' ) 如何获得完整的差异 使用phpunit 5.0.8和php5.6.14而不使用xdebug,原因很明显,您无法在CLI中使用它。但是,在某些高级IDE(例如PHPStorm)中使用PHPUnit可以让您同时
Failed asserting that two arrays are equal.
--- Expected
+++ Actual
@@ @@
Array (
+ 0 => 'Argument $name does match typ...string'
)
如何获得完整的差异
使用phpunit 5.0.8和php5.6.14而不使用xdebug,原因很明显,您无法在CLI中使用它。但是,在某些高级IDE(例如PHPStorm)中使用PHPUnit可以让您同时比较您的期望和实际结果。>很明显,您的CLI中不能使用它,您的意思是因为PHPUnit使用的实现不同?不,因为输出可能是巨大而复杂的。有没有办法调整这个限制?我的经验是用只有2或三个级别的数组来截断,并且字符串有512个,但仍然会考虑得到整个输出。