Iterable return types should return empty array by default#4678
Merged
sebastianbergmann merged 1 commit intosebastianbergmann:8.5from May 20, 2021
Slamdunk:iterable_empty_return
Merged
Iterable return types should return empty array by default#4678sebastianbergmann merged 1 commit intosebastianbergmann:8.5from Slamdunk:iterable_empty_return
sebastianbergmann merged 1 commit intosebastianbergmann:8.5from
Slamdunk:iterable_empty_return
Conversation
williamdes
added a commit
to phpmyadmin/phpmyadmin
that referenced
this pull request
May 29, 2023
This did happen to me in Ubuntu while packaging, until now I did not understand it correctly. It's a phpunit bug for sure, patched in 8.5.16. Most probably due to sebastianbergmann/phpunit#4678 ``` 1) PhpMyAdmin\Tests\TableTest::testDuplicateInfo Invalid argument supplied for foreach() libraries/classes/Table.php:944 test/classes/TableTest.php:955 phpvfscomposer://vendor/phpunit/phpunit/phpunit:60 ``` Signed-off-by: William Desportes <williamdes@wdes.fr>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Without this fix, mocked method with
traversable|Generator|iterablereturn types return an array with onenullelement:https://3v4l.org/mR8kdU