Skip to content

Commit

Permalink
Revert cy.wrap for readFile config
Browse files Browse the repository at this point in the history
  • Loading branch information
RioKnightleyNHS committed Dec 1, 2023
1 parent 080cea4 commit 9805f30
Showing 1 changed file with 4 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,9 @@ describe('GP Workflow: View Lloyd George record', () => {
cy.getByTestId('actions-menu').click();
cy.getByTestId('download-all-files-link').click();

cy.wait('@documentManifest');

// Assert contents of page when downloading
cy.contains('Downloading documents').should('be.visible');
cy.contains(
`Preparing download for ${viewLloydGeorgePayload.number_of_files} files`,
Expand All @@ -52,11 +55,7 @@ describe('GP Workflow: View Lloyd George record', () => {
cy.contains(`(NHS number: ${searchPatientPayload.nhsNumber})`).should('be.visible');

// Assert file has been downloaded
cy.wrap(
Cypress.config('downloadsFolder').then((path) =>
cy.readFile(path + '/browserconfig.xml'),
),
);
cy.readFile(`${Cypress.config('downloadsFolder')}/browserconfig.xml`);

cy.getByTestId('return-btn').click();

Expand Down

0 comments on commit 9805f30

Please sign in to comment.