@Test public void shouldGetById() throws Exception { when(mapper.getById(1L)).thenReturn(new ServiceContract()); repository.getById(1L); verify(mapper).getById(1L); }
public ServiceContract getById(Long id){ return mapper.getById(id); }
ServiceContractRepository { public ServiceContract getById(Long id){ return mapper.getById(id); } }
ServiceContractRepository { public ServiceContract getById(Long id){ return mapper.getById(id); }  }
ServiceContractRepository { public ServiceContract getById(Long id){ return mapper.getById(id); }  ServiceContract getById(Long id); List<ServiceContract> getAllForFacility(Long facilityId); List<ServiceContract> getAllForVendor(Long vendorId); List<ServiceContract> getAllForEquipment(Long equipmentId); List<ServiceContract> getAll(); void insert(ServiceContract value); void update(ServiceContract value); }
ServiceContractRepository { public ServiceContract getById(Long id){ return mapper.getById(id); }  ServiceContract getById(Long id); List<ServiceContract> getAllForFacility(Long facilityId); List<ServiceContract> getAllForVendor(Long vendorId); List<ServiceContract> getAllForEquipment(Long equipmentId); List<ServiceContract> getAll(); void insert(ServiceContract value); void update(ServiceContract value);  }