@Test
public void updateRawContent() throws Exception {

    String dataSetId = UUID.randomUUID().toString();
    DataSetMetadata dataSetMetadata = metadataBuilder.metadata().id(dataSetId).build();
    dataSetMetadataRepository.save(dataSetMetadata);
    given()
            .body(IOUtils.toString(this.getClass().getResourceAsStream(TAGADA_CSV), UTF_8))
            .when()
            .put("/datasets/{id}/raw", dataSetId)
            .then()
            .statusCode(OK.value());
    List<String> ids = from(when().get("/datasets").asString()).get("id");
    assertThat(ids, hasItem(dataSetId));
    assertQueueMessages(dataSetId);
    given()
            .body(IOUtils.toString(this.getClass().getResourceAsStream("../avengers.csv"), UTF_8))
            .when()
            .put("/datasets/{id}/raw", dataSetId)
            .then()
            .statusCode(OK.value());
    ids = from(when().get("/datasets").asString()).get("id");
    assertThat(ids, hasItem(dataSetId));
    assertQueueMessages(dataSetId);
}