Skip to content
This repository was archived by the owner on Mar 12, 2025. It is now read-only.

Register the SymfonyTestListener with the correct state #40

Merged
merged 1 commit into from
Sep 12, 2018

Conversation

acrobat
Copy link
Contributor

@acrobat acrobat commented Aug 30, 2018

We don't register the symfony listener as a global listener. So we should make sure we disable the global state.

Without this fix the @expectedDeprecation (and ClockMock, DnsMock, etc) won't work because the internal state of the listener is "-2" aka global listener. With this fix the listener gets the correct state of "0", the same as you would get when registering the listener within the phpunit.xml config.

@acrobat
Copy link
Contributor Author

acrobat commented Sep 6, 2018

Ping @DavertMik @Naktibalda

Copy link
Member

@Naktibalda Naktibalda left a comment

Choose a reason for hiding this comment

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

If you say that it solves an issue, then it probably does.

I see nothing wrong with this change, but I will leave it for @DavertMik to merge.

@DavertMik
Copy link
Member

Yeah, let's hope it fixes something and doesn't break anything.
I'm not so deep in Symfony internals

@DavertMik DavertMik merged commit de922c7 into Codeception:6.0 Sep 12, 2018
@acrobat acrobat deleted the symfony-listiner-state-fix branch September 13, 2018 06:57
@acrobat
Copy link
Contributor Author

acrobat commented Sep 28, 2018

@DavertMik @Naktibalda is it possible to have a new v6 release with this fix included? Thanks!

@Naktibalda
Copy link
Member

done.

@Naktibalda
Copy link
Member

6.0.12 and 7.3.1

@acrobat
Copy link
Contributor Author

acrobat commented Sep 28, 2018

Thanks a lot!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants