Skip to content

Commit c58c266

Browse files
committed
Fix direct comparison in run-tests.php differ
1 parent 7e22419 commit c58c266

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

run-tests.php

+3-3
Original file line numberDiff line numberDiff line change
@@ -3982,11 +3982,11 @@ public function diffToArray(array $from, array $to): array
39823982
reset($to);
39833983

39843984
foreach ($common as $token) {
3985-
while (($fromToken = reset($from)) !== $token) {
3985+
while (!($this->isEqual)($fromToken = reset($from), $token)) {
39863986
$diff[] = [array_shift($from), self::REMOVED, $fromLine++];
39873987
}
39883988

3989-
while (($toToken = reset($to)) !== $token) {
3989+
while (!($this->isEqual)($toToken = reset($to), $token)) {
39903990
$diff[] = [array_shift($to), self::ADDED, $toLine++];
39913991
}
39923992

@@ -4041,7 +4041,7 @@ private function getArrayDiffParted(array &$from, array &$to): array
40414041
$fromK = key($from);
40424042
$toK = key($to);
40434043

4044-
if (null === $fromK || null === $toK || current($from) !== current($to)) {
4044+
if (null === $fromK || null === $toK || !($this->isEqual)(current($from), current($to))) {
40454045
break;
40464046
}
40474047

0 commit comments

Comments
 (0)