Phpunit fix invisible array values in diff view – Array (…)

To show full array difference in diff viewer of phpunit in phpstorm (<Click to see difference>) instead of Array (…)

for PHPUnit’s assertEquals and assertSame

change in vendor

\SebastianBergmann\Exporter\Exporter::shortenedExport

to

        if (is_array($value)) {
//            return sprintf(
//                'Array (%s)',
//                count($value) > 0 ? '...' : ''
//            );
        }

comment out changes above

around line: 125
for PHPUnit v7

to achieve same effect in assertSame:
in file:
\SebastianBergmann\Exporter\Exporter::recursiveExport
around line 251

 if (\is_array($value)) {
//            if (($key = $processed->contains($value)) !== false) {
//                return 'Array &' . $key;
//            }
//
//            $array  = $value;
//            $key    = $processed->add($value);
//            $values = '';
//
//            if (\count($array) > 0) {
//                foreach ($array as $k => $v) {
//                    $values .= \sprintf(
//                        '%s    %s => %s' . "\n",
//                        $whitespace,
//                        $this->recursiveExport($k, $indentation),
//                        $this->recursiveExport($value[$k], $indentation + 1, $processed)
//                    );
//                }
//
//                $values = "\n" . $values . $whitespace;
//            }
//
//            return \sprintf('Array &%s (%s)', $key, $values);
        }