title: PHPUnit mock all methods of an abstract class
body: <p>I have a PHPUnit test case directly deriving from PHPUnit_Framework_TestCase. In a test in this class I need to get a mock for some service object. This service object is of a type defined by an abstract base class. This base class holds both concrete and abstract methods. I want to get a full mock for the thing (ie all methods mocked out). My question is how to do this.</p>
  
  <p>->getMock gives me an error since the abstract methods are not mocked, only the concrete ones</p>
  
  <p>->getMockForAbstractClass mocks out the abstract methods but not the concrete ones</p>
  
  <p>How do I mock them all out?</p>
  
  <p>(I'm using PHPUnit 3.7.13)</p>