Keep PHP 5.6 compactibility#449
Conversation
|
Yes, indeed we want to keep PHP 5.6 compatibility in this release, thanks! I believe we need to keep the void return type hint to be compatible with latest PHPUnit though. Maybe we can make a separate |
|
I have reverted the trait. Talking about separate trait for legacy phpunit it would be quite hard to find working case. As I see that trait is used specifically in Laravel tests. And the last version of phpunit supporting is 5. I took a look into laravel framework repository and latest version of laravel using that phpunit version is 5.4. I would suggest to skip implementing legacy trait for that for the moment. |
|
Yeah, we do support Laravel 5.0+, but I've only tested the trait with recent PHPUnit/Laravel versions. Will wait until someone asks for it before investing more time into the legacy stuff. Thanks for the PR! |
|
I recommend adding phpdoc typehints as it allows autocomplete in IDEs. It is also worth to consider adding phpstan tests, which will make the code quality much better as it points out issues with the typehints and finds issues in the code. |
|
How can you improve what's already perfect? 🙃 |
|
I think compatibility with Laravel 5.2 is broken (also newer versions) because of non existing method |
composer.json states that we can use PHP >= 5.6, however using group uses in the code causes fatal errors. I have split them to keep up PHP 5.6 compatibility.