source: class GenericSyncServiceTest {
  
      @Mock
      private ChildRepository repository;
      @Mock
      private User currentUser;
      private RapidFtrApplication application;
       FluentRequest fluentRequest;
      public static final String RESPONSE;
       EntityHttpDao<Child> childHttpDao;
       MediaSyncHelper mediaSyncHelper;
       GenericSyncService<Child> genericSyncService;
  
      @Test
      public void shouldNotAddAudioRecordedToTheRequestIfItsAlreadyPresentInServer() throws JSONException, IOException, HttpException {
  
target:         getFakeHttpLayer().setDefaultHttpResponse(201, RESPONSE);
          Child child = new Child("id", "user", "{'_id' : 'abcd123488', 'name' : 'child1', 'recorded_audio' : '123455', 'audio_attachments' : {'original' : '123455', 'amr':'123455'}}");
          EntityHttpDao<Child> httpDao = new EntityHttpDao<Child>(application, "", "", "child");
          EntityHttpDao<Child> spyHttpDao = spy(httpDao);
          doReturn(child).when(spyHttpDao).update(any(Child.class), any(String.class), any(Map.class));
  
          new GenericSyncService<Child>(mediaSyncHelper, spyHttpDao, repository).sync(child, "api/children");
  
          verify(spyHttpDao).update(any(Child.class), any(String.class), argThat(new DoesntContainAudioKeyParams()));
      }
  
  }