Skip to content
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

Allow Symfony 6.0 & Updated tests according to changes #51

Merged
merged 1 commit into from
Dec 23, 2021

Conversation

yann-eugone
Copy link
Collaborator

No description provided.

@codecov-commenter
Copy link

Codecov Report

Merging #51 (9e8b3b3) into 4.x (01744ff) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@             Coverage Diff             @@
##                 4.x       #51   +/-   ##
===========================================
  Coverage     100.00%   100.00%           
  Complexity        89        89           
===========================================
  Files             18        18           
  Lines            251       251           
===========================================
  Hits             251       251           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 01744ff...9e8b3b3. Read the comment docs.

*/
class Translator implements TranslatorInterface
{
if (Kernel::MAJOR_VERSION >= 6) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is this check about?

Copy link
Collaborator Author

@yann-eugone yann-eugone Dec 23, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In Symfony 6, the TranslatorInterface::trans method has parameter and return typehint.

The diff might be a bit tricky but it is about creating 2 implementation of the same class, depending on Symfony's version.

https://github.com/yokai-php/enum-bundle/blob/9e8b3b303ed02d373edb0bd657210d1bfb4bb091/tests/Unit/Translator.php

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Right, as a matter of fact I was confused by the diff...

@yann-eugone yann-eugone merged commit e98614b into 4.x Dec 23, 2021
@yann-eugone yann-eugone deleted the compatibility-with-symfony-6.0 branch July 8, 2024 13:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants