Skip to content
Snippets Groups Projects
Commit 09b9410b authored by OZGCloud's avatar OZGCloud
Browse files

OZG-3262 fix e2e tests

parent 92482ef7
No related branches found
No related tags found
No related merge requests found
......@@ -99,7 +99,7 @@ describe('Vorgang Anhänge', () => {
attachmentContainer.getList().getItem(jpgAttachmentName).getRoot().click();
waitForSpinnerToDisappear();
exist(readFileFromDownloads(jpgAttachmentName));
exist(readFileFromDownloads(buildDownloadFileName(jpgAttachmentName)));
})
it('should download pdf', () => {
......@@ -107,7 +107,7 @@ describe('Vorgang Anhänge', () => {
attachmentContainer.getList().getItem(convertToDataTestId(pdfAttachmentName)).getRoot().click();
waitForSpinnerToDisappear();
exist(readFileFromDownloads(pdfAttachmentName));
exist(readFileFromDownloads(buildDownloadFileName(pdfAttachmentName)));
})
it('should navigate to vorganglist on back button', () => {
......@@ -146,7 +146,7 @@ describe('Vorgang Anhänge', () => {
attachmentContainer.getList().getItem(xmlRepresentation.name).getRoot().click();
waitForSpinnerToDisappear();
exist(readFileFromDownloads(xmlRepresentation.name));
exist(readFileFromDownloads(buildDownloadFileName(xmlRepresentation.name)));
})
it('should navigate to vorganglist on back button', () => {
......@@ -156,4 +156,12 @@ describe('Vorgang Anhänge', () => {
exist(vorgangList.getRoot());
})
})
function buildDownloadFileName(fileName: string): string{
return `${getFileNamePrefix()}_${fileName}`;
}
function getFileNamePrefix(): string {
return vorgangAnhangVorhanden.nummer;
}
})
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment