->getMockBuilder()->setMethods() 4/4 setMethods() has 4 possible outcomes Pass an array with method names – Methods identified are stubs Return null Easily overridable – Methods *not* identified are mocks Actual code is ran Unable to override $payment = $this->getMockBuilder( Payment ) ->setMethods( array( authorizeAndCapture ,) ) ->getMock();
{}