I\'m new to unit testing and PHPUnit.
I need a mock, on which I have a full control, implementing ConfigurationInterface
interface. Test subject is Re
Tyler Collier's warning is fair but doesn't contain a code snippet on how to code around it. Note this is very nasty and you should fix the interface instead. With that warning added:
$methods = array_map(function (\ReflectionMethod $m) { return $m->getName();}, (new \ReflectionClass($interface))->getMethods());
$methods[] = $missing_method;
$mock = $this->getMock($interface, $methods);