Skip to content

[Messenger] Fix broken mock #41558

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

Merged
merged 1 commit into from
Jun 6, 2021

Conversation

derrabus
Copy link
Member

@derrabus derrabus commented Jun 5, 2021

Q A
Branch? 5.3
Bug fix? yes
New feature? no
Deprecations? no
Tickets Part of #41552
License MIT
Doc PR N/A

In reality, $response->getInfo('http_code') will always yield an integer, but the mock created in AmazonSqsTransportTest will return null. This causes trouble on PHP 8.1 because the status code is eventually passed as $code to an exception constructor that does not allow null values anymore.

Copy link
Member

@Nyholm Nyholm left a comment

Choose a reason for hiding this comment

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

One thing to be extra green

Signed-off-by: Alexander M. Turek <me@derrabus.de>
@derrabus derrabus force-pushed the bugfix/messenger-broken-mock branch from c254d3b to 7d1435b Compare June 6, 2021 07:21
Copy link
Member

@Nyholm Nyholm left a comment

Choose a reason for hiding this comment

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

Thank you

@nicolas-grekas
Copy link
Member

Thank you @derrabus.

@nicolas-grekas nicolas-grekas merged commit dbe480a into symfony:5.3 Jun 6, 2021
@derrabus derrabus deleted the bugfix/messenger-broken-mock branch June 6, 2021 08:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants