New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for Symfony 5 #266
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since it's coming in the next 30 days, this is probably a good time to do it.
Please add an entry in the changelog!
@Jean85 Done |
@Jean85 Your move ) |
Sorry I'm at SymfonyCon so I didn't had the time to check it 😄 But I saw the release live 🎉 I'm going to re-start the CI to see if everything is ok.... |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
PR seems fine, but unfortunately it seems that we're blocked upstream: getsentry/sentry-php#925 (review)
We're missing an integration test, that's why we missed this 😢 I'll need to setup a test like that before going forward. |
Symfony 5 is still not getting installed 😢 There's something amiss with the CI config. I'll try to force it somehow. |
Conflict solved, build is failing :( |
Hey, thank you for trying to push this PR forward! <3 I'm trying to help:
You need to change
You do not have to mock value objects. You can just instantiate them. These include:
Of course, you can mock the service away. If you want, I can try to finish this PR on the weekend. |
@DavidBadura yes please, do it. |
Thanks @DavidBadura for the suggestions, I've implemented it. I've also removed some pieces of code that were needed for Symfony < 3.3. |
I should've fixed all the tests. Now onto fixing PHPStan. |
@Jean85 Hey! The remaining errors seems related to the PHP Unit version. The current version is 8.5 while the bundle uses the 7.5 |
In reality I did a mistake with the class aliases. I fear that something else is still missing, let's see the CI after this fix... |
@Jean85 need help? |
I'm currently getting deprecation errors under PHP 7.4, probably from PHPUnit. I'll try to use the PHPUnit bridge to allow PHPUnit 8 |
Ok two other issues:
|
@Jean85 I see that phpunit-bridge has "normal" versions, why do you want to ignore it in sed replace? |
@Jean85 deprecation could be probably solved by allowing phpunit 8 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
to fix phpunit deprecation, I use rector rector process --set phpunit8.0 .
"symfony/browser-kit": "^3.4||^4.0", | ||
"symfony/expression-language": "^3.4||^4.0", | ||
"symfony/framework-bundle": "^3.4||^4.0", | ||
"phpunit/phpunit": "^7.5||^8.5", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
remove this, and let symfony/phpunit-bridge
pick the right version ./vendor/bin/simple-phpunit
private $currentScope; | ||
private $currentHub; | ||
private $options; | ||
|
||
protected function setUp() | ||
protected function doSetUp(): void |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not needed, because the projet require php ^7.1n you can saftly add the typehint here setUp(): void
Because the trait is missing. But as per #266 (comment), I may not need it. BTW the PHPUnit bridge has no requirements, so you do not need to downgrade it. |
PHP 7.4 deprecations will be fixed by getsentry/sentry-php#930 upstream. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It finally works!
Remaining deprecations will be fixed when getsentry/sentry-php#930 will be tagged.
@Jean85 great job everyone! 👏 Planning on releasing soon? If not I'll verify by requiring |
Normally @HazAT is in charge of releasing. Feel free to test it out! |
No description provided.