-
Notifications
You must be signed in to change notification settings - Fork 30
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 phpstan 1.0 #266
Conversation
9e8e811
to
2e0fe96
Compare
message: "#^Call to an undefined method Prophecy\\\\Prophecy\\\\ObjectProphecy\\:\\:doubleTheNumber\\(\\)\\.$#" | ||
count: 1 | ||
message: "#^Call to an undefined method Prophecy\\\\Prophecy\\\\ObjectProphecy\\<JanGregor\\\\Prophecy\\\\Test\\\\StaticAnalysis\\\\Src\\\\BaseModel\\>\\:\\:doubleTheNumber\\(\\)\\.$#" | ||
count: 2 |
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.
I'm little bit curious why this count did increase. Not sure if I did something wrong in the baseline update, hope you can have a look at it if I did all correctly.
But think aslong as the other file has no error included the plugin works like expected.
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.
that's not only a count increase. It shows an modified message too.
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.
The object was changed by me to have 0 errors when using with the extension. Not sure but I think when the run shows 0 errors when extension is enabled and show this errors when extension not enabled we should be fine.
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 me, that's fine indeed, based on the change you made.
655018f
to
228187d
Compare
@@ -62,11 +62,13 @@ public function getTypeFromMethodCall( | |||
return $returnType; | |||
} | |||
|
|||
if (0 === \count($methodCall->args)) { | |||
$args = $methodCall->getArgs(); |
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.
Think @Jan0707 is not longer active on github. @localheinz would be great if you could have a look at this if you maybe got some time for it. If somebody want to test or use it already add the following to your "repositories": [
{
"type": "vcs":
"url": "[email protected]:alexander-schranz/phpstan-prophecy.git"
}
],
..
"require-dev": {
"jangregor/phpstan-prophecy": "dev-patch-1 as 1.0.0"
} |
0ad23f8
to
662754c
Compare
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.
👍
Thank you, @alexander-schranz and @stof! |
We are using this package in @sulu CMS and as phpstan 1.0 was released I thought it would be great to support the new phpstan version. This PR will set the required phpstan version to 1.0. Would I think be also a good time to tag also this package with 1.0 thats why I did not add it as additional allowed version.