@Test
public void uploadDataTest() throws Exception {

    // Setup:
    FormDataMultiPart fd = new FormDataMultiPart();
    fd.bodyPart(new FormDataBodyPart(FormDataContentDisposition.name("file").fileName("test.ttl").build(),
            getClass().getResourceAsStream("/test.ttl"), MediaType.APPLICATION_OCTET_STREAM_TYPE));
    Response response = target().path("datasets/" + encode(record1.getResource().stringValue()) + "/data")
            .request().post(Entity.entity(fd, MediaType.MULTIPART_FORM_DATA));
    assertEquals(response.getStatus(), 200);
    verify(importService).importInputStream(any(ImportServiceConfig.class), any(InputStream.class));
}