in src/it/java/com/epam/digital/data/platform/el/juel/it/digdocument/SaveDigitalDocumentJuelFunctionIT.java [51:68]
void shouldReturnCorrectDocumentMetadataForRootProcess() throws IOException {
mockConnectToKeycloak();
mockConnectToDocumentService();
var processInstance = runtimeService().startProcessInstanceByKey(
"root_process_with_file_saving");
assertThat(processInstance).isEnded();
var rootProcessInstanceId = processInstance.getId();
digitalDocumentService.verify(
postRequestedFor(urlPathEqualTo("/internal-api/v2/documents/" + rootProcessInstanceId))
.withQueryParam("filename", equalTo("file.txt"))
.withRequestBodyPart(aMultipart("file.txt")
.withHeader("Content-Type", equalTo("text/plain"))
.withBody(binaryEqualTo(new byte[]{1, 2, 3})).build()));
}