Skip to content

Commit

Permalink
[DURACOM-328] fix test
Browse files Browse the repository at this point in the history
  • Loading branch information
steph-ieffam committed Feb 26, 2025
1 parent f787e0b commit a6529b4
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2253,15 +2253,15 @@ public void deleteBitstreamTest()
context.restoreAuthSystemState();
String tokenSubmitter = getAuthToken(submitter.getEmail(), password);
List<Operation> deleteFile = new ArrayList<>();
deleteFile.add(new RemoveOperation("/sections/bitstream-metadata-publication/files/0/"));
deleteFile.add(new RemoveOperation("/sections/upload-no-required-metadata/files/0/"));
getClient(tokenSubmitter).perform(patch("/api/submission/workspaceitems/" + witem.getID())
.content(getPatchContent(deleteFile))
.contentType(MediaType.APPLICATION_JSON_PATCH_JSON))
.andExpect(status().isOk());
// verify that the patch removed bitstream
getClient(tokenSubmitter).perform(get("/api/submission/workspaceitems/" + witem.getID()))
.andExpect(status().isOk())
.andExpect(jsonPath("$.sections.bitstream-metadata-publication.files",hasSize(0)));
.andExpect(jsonPath("$.sections.upload-no-required-metadata.files",hasSize(0)));
}

}

0 comments on commit a6529b4

Please sign in to comment.