Skip to content

Commit

Permalink
test: ArrayHash test compatible with PHP 7.2
Browse files Browse the repository at this point in the history
  • Loading branch information
dg committed Jul 21, 2017
1 parent eb56385 commit 62bbd4f
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion tests/Utils/ArrayHash.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,11 @@ test(function () { // numeric fields
foreach ($row as $key => $value) {
$keys[] = $key;
}
Assert::same(['0', '1'], $keys);
if (PHP_VERSION_ID < 70200) {
Assert::same(['0', '1'], $keys);
} else {
Assert::same([0, 1], $keys);
}

Assert::same(1, $row->{0});
Assert::same(1, $row->{'0'});
Expand Down

0 comments on commit 62bbd4f

Please sign in to comment.