Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added regression test for requests page #8608

Merged
merged 12 commits into from
Oct 30, 2024
19 changes: 19 additions & 0 deletions tests/cypress/e2e/features/requests_page.js
Original file line number Diff line number Diff line change
Expand Up @@ -357,5 +357,24 @@ context('Requests page', () => {
});
});
});

it('Export task. Request for status fails, UI is not crushing', () => {
cy.intercept('GET', '/api/requests/**', {
statusCode: 500,
body: 'Network error',
});
klakhov marked this conversation as resolved.
Show resolved Hide resolved

cy.exportTask({
type: 'annotations',
format: exportFormat,
archiveCustomName: annotationsArchiveNameLocal,
});

cy.contains('Could not export dataset').should('be.visible');
cy.closeNotification('.ant-notification-notice-error');

cy.contains('.cvat-header-button', 'Requests').should('be.visible').click();
cy.get('.cvat-requests-page').should('be.visible');
});
});
});
2 changes: 1 addition & 1 deletion tests/cypress/support/commands.js
Original file line number Diff line number Diff line change
Expand Up @@ -1272,7 +1272,7 @@ Cypress.Commands.add('exportTask', ({
cy.get('.cvat-cloud-storage-select-provider').click();
}
}
cy.contains('button', 'OK').click();
cy.contains('.cvat-modal-export-task button', 'OK').click();
cy.get('.cvat-notification-notice-export-task-start').should('be.visible');
cy.closeNotification('.cvat-notification-notice-export-task-start');
});
Expand Down
Loading