@Override
  public ImportResult importItem(UUID jobId,
      IdempotentImportExecutor idempotentExecutor,
      TokensAndUrlAuthData authData, ContactsModelWrapper data) throws Exception{
    JCardReader reader = new JCardReader(data.getVCards());
    try {
      // TODO(olsona): address any other problems that might arise in conversion
      List<VCard> vCardList = reader.readAll();
      PeopleService.People peopleService = getOrCreatePeopleService(authData).people();
      for (VCard vCard : vCardList) {
        Person person = convert(vCard);
        idempotentExecutor.executeAndSwallowIOExceptions(
            vCard.toString(),
            vCard.getFormattedName().toString(),
            () -> peopleService.createContact(person).execute().toPrettyString());
      }
      return ImportResult.OK;
    } catch (IOException e) {
      return new ImportResult(e);
    }
  }
@Test
  public void importFirstResources() throws Exception {
    // Set up: small number of VCards to be imported
    int numberOfVCards = 5;
    List<VCard> vCardList = new LinkedList<>();
    for (int i = 0; i < numberOfVCards; i++) {
      StructuredName structuredName = new StructuredName();
      structuredName.setFamily("Family" + i);
      structuredName.setParameter(SOURCE_PARAM_NAME_TYPE, CONTACT_SOURCE_TYPE);
      VCard vCard = new VCard();
      vCard.setStructuredName(structuredName);
      vCard.setFormattedName("First " + structuredName.getFamily());
      vCardList.add(vCard);
    }
    String vCardString = GoogleContactsExporter.makeVCardString(vCardList);
    ContactsModelWrapper wrapper = new ContactsModelWrapper(vCardString);

    // Run test
    contactsService.importItem(UUID.randomUUID(), executor,null, wrapper);

    // Check that the right methods were called
    verify(people, times(numberOfVCards)).createContact(any(Person.class));
    verify(createContact, times(numberOfVCards)).execute();
  }