ExpectationInterface is missing methods that the Expectation class has.
Hi,
I have a problem with static analysis of our tests. We have recently introduced phpstan into our company project. We have succefully fixed all errors in the production code. We have also fixed almost all errors in our tests as well. The only exception are problems with mockery, where methods claim to return some interface (ExpectationInterface), but what they really return is the Expectation class. We are calling methods like once(), with(), etc. on the expectation which works fine and the tests are ok. But the static analysis of the tests code is yelling at us that there are errors calling undefined methods, because the ExpectationInterface does not have those, but the Expectation class does, but the static analysis tool doesnt know about that. Would it be possible to add these methods on the interface as well? Or what is the reason for those methods being only part of the class and not the interface?
Source: mockery/mockery