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

CRDCDH-882 Validation Results CSV Export & Jest Improvements #313

Merged
merged 21 commits into from
Apr 2, 2024

Conversation

amattu2
Copy link
Member

@amattu2 amattu2 commented Mar 18, 2024

Overview

This PR introduces functionality to export Validation Results to a CSV file and makes minor changes to our Jest setup.

Important

Jest MUST BE configured to run through our npm run test -- script otherwise certain tests that rely on the setupTests.ts script will fail

Change Details (Specifics)

  • Create a setupTests.ts file for Jest and remove duplicate imports (axe and testing library)
  • Create a mock function for Notistack to enable testing the error message outputs
  • Add functionality to generate a CSV export of all validation results
  • Add test coverage for utils added
  • Add test coverage for Export Button and Apollo queries
  • Upgrade Apollo GraphQL
    • In 3.8+ MockedProvider supports functions to generate dynamic a response, needed this for some tests

Note

Test on submissions with under 30K results as the API doesn't support above 30K atm.

Note

The error messages currently contain non-standard double quotation marks which do not render in Excel. The frontend replaces them with a standard " to prevent issues.

Related Ticket(s)

CRDCDH-882

@amattu2 amattu2 added this to the 3.0.0 (PMVP-M1) milestone Mar 18, 2024
@amattu2 amattu2 changed the title CRDCDH-882 Validation Results CSV Export CRDCDH-882 Validation Results CSV Export & Jest Improvements Mar 20, 2024
@amattu2 amattu2 added the 🚧 Do Not Merge This PR is not ready for merging label Mar 28, 2024
@amattu2 amattu2 marked this pull request as ready for review March 28, 2024 17:30
@amattu2 amattu2 removed the 🚧 Do Not Merge This PR is not ready for merging label Mar 29, 2024
Copy link
Collaborator

@Alejandro-Vega Alejandro-Vega left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Very nice!

@Alejandro-Vega Alejandro-Vega merged commit 0afa716 into 3.0.0 Apr 2, 2024
3 checks passed
@Alejandro-Vega Alejandro-Vega deleted the CRDCDH-882 branch April 2, 2024 14:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants