title: Mockery - Unexpected Expectations - Not sure what I am doing wrong
body: <p>I have a service with the following interface : </p>
  
  <pre><code>public interface accountsService {
  
      public accountRemovalModel purgeAccounts();
  }
  </code></pre>
  
  <p>I have to following test class : </p>
  
  <p>I have a service with the following interface : </p>
  
  <pre><code>public interface AccountsService {
  
      public accountRemovalModel purgeAccounts();
  }
  </code></pre>
  
  <p>I have to following test class : </p>
  
  <pre><code>public class AccountsServiceTest extends BaseTestClass {
  
      private Mockery _m = new Mockery() {
      {
          setImposteriser(ClassImposteriser.INSTANCE);
      }};
  
  
      private accountsService _accountsService;
  
      @Before
      public void beforeTests() throws Exception {
  
          accountsService = _m.mock(AccountsService.class);
      }
  
      @Test
      public void testNoItemsToDeleteSuccess() throws Exception {
  
          // Return a simple AccountsRemovalModel
          // APPARENTLY THIS EXPECTATION IS UNEXPECTED?
          _m.checking(new Expectations() {{
  
              allowing(accountsService.purgeAccounts());
              will(returnValue(new accountRemovalModel(0,0)));
          }});
  
          accountsRemovalModel result = accountsService.purgeAccounts();
  
          Assert.assertEquals(0, result.getDeleteCount());
          Assert.assertEquals(0, result.getTotalCount());
      }
  }
  </code></pre>
  
  <p>I am getting the following error : </p>
  
  <p>AccountsServiceTest.testNoItemsToDeleteSuccess:23 » Expectation unexpected...</p>
  
  <p>Any help with this is greatly appreciated - as I am having big problems with getting this to work!</p>