Skip to content

Revert #441: #526

Open
Jean85 wants to merge 12 commits intophpspec:masterfrom
Jean85:revert-441
Open

Revert #441: #526
Jean85 wants to merge 12 commits intophpspec:masterfrom
Jean85:revert-441

Conversation

@Jean85
Copy link
Copy Markdown
Contributor

@Jean85 Jean85 commented Mar 17, 2021

Fixes #472, declares a new major bump to 2.0.

As suggested by @stof in #472 (comment), this is an attempt to revert #441 and go back to the old behavior, with a fast bailout when the prophecy hits an unregistered method call.
This avoids returning null in those cases, since it would probably lead to \TypeErrors or other unpredictable behaviours, as originally pointed out in https://github.com/phpspec/prophecy/pull/441/files#r388191626.

Comment thread spec/Prophecy/Prophecy/MethodProphecySpec.php Outdated
@Jean85
Copy link
Copy Markdown
Contributor Author

Jean85 commented Mar 17, 2021

Ouch, we would need to declare PHPSpec compatible with Prophecy 2.0 in advance 😢 I'll revert the dev-master alias change to make the build happy.

@ciaranmcnulty
Copy link
Copy Markdown
Member

If we're going to bump the version number we should re-think the behaviour more comprehensively

What do you think of #528 ?

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.

Callcenter returns null on non registered method call

4 participants