From 8f354fbae23ee3d7bf284c60e187c94d31d6a7c8 Mon Sep 17 00:00:00 2001 From: ruizajtruss Date: Fri, 26 Apr 2024 22:04:08 +0000 Subject: [PATCH] something isnt working here WIP --- .../pages/StateSubmission/StateSubmissionForm.tsx | 4 ++-- .../integration/cmsWorkflow/viewSubmission.spec.ts | 1 + .../stateSubmissionForm/rateDetails.spec.ts | 10 +++++++++- .../cypress/support/stateSubmissionFormCommands.ts | 13 ++++++++++++- 4 files changed, 24 insertions(+), 4 deletions(-) diff --git a/services/app-web/src/pages/StateSubmission/StateSubmissionForm.tsx b/services/app-web/src/pages/StateSubmission/StateSubmissionForm.tsx index a8f77c85e1..fb25c4f63d 100644 --- a/services/app-web/src/pages/StateSubmission/StateSubmissionForm.tsx +++ b/services/app-web/src/pages/StateSubmission/StateSubmissionForm.tsx @@ -53,7 +53,7 @@ export const StateSubmissionForm = (): React.ReactElement => { 'SUBMISSIONS_RATE_DETAILS' )} element={ - useLinkedRates ? ( + !useLinkedRates ? ( ) : ( @@ -77,7 +77,7 @@ export const StateSubmissionForm = (): React.ReactElement => { 'SUBMISSIONS_REVIEW_SUBMIT' )} element={ - useLinkedRates ? : + !useLinkedRates ? : } /> } /> diff --git a/services/cypress/integration/cmsWorkflow/viewSubmission.spec.ts b/services/cypress/integration/cmsWorkflow/viewSubmission.spec.ts index d6453c6b9a..5a818f1441 100644 --- a/services/cypress/integration/cmsWorkflow/viewSubmission.spec.ts +++ b/services/cypress/integration/cmsWorkflow/viewSubmission.spec.ts @@ -14,6 +14,7 @@ describe('CMS user can view submission', () => { level: 2, name: /Rate details/, }).should('exist') + cy.fillOutNewRateCertification() cy.fillOutAdditionalActuaryContact() cy.navigateFormByButtonClick('CONTINUE') diff --git a/services/cypress/integration/stateWorkflow/stateSubmissionForm/rateDetails.spec.ts b/services/cypress/integration/stateWorkflow/stateSubmissionForm/rateDetails.spec.ts index 19f5d6a3a1..9e85704d54 100644 --- a/services/cypress/integration/stateWorkflow/stateSubmissionForm/rateDetails.spec.ts +++ b/services/cypress/integration/stateWorkflow/stateSubmissionForm/rateDetails.spec.ts @@ -31,7 +31,7 @@ describe('rate details', () => { }) }) - it('can add amendment to prior rate certification', () => { + it.only('can add amendment to prior rate certification', () => { cy.logInAsStateUser() cy.startNewContractAndRatesSubmission() @@ -112,6 +112,14 @@ describe('rate details', () => { }) } ) + cy.findByRole('radiogroup', { + name: /Actuaries' communication preference/ + }) + .should('exist') + .within(() => { + cy.findByText("OACT can communicate directly with the state's actuaries but should copy the state on all written communication and all appointments for verbal discussions.") + .click() + }) // Navigate to contacts page by clicking continue cy.navigateFormByButtonClick('CONTINUE') diff --git a/services/cypress/support/stateSubmissionFormCommands.ts b/services/cypress/support/stateSubmissionFormCommands.ts index 0d720d3c07..5e5bf35255 100644 --- a/services/cypress/support/stateSubmissionFormCommands.ts +++ b/services/cypress/support/stateSubmissionFormCommands.ts @@ -369,6 +369,9 @@ Cypress.Commands.add('fillOutNewRateCertification', () => { cy.findAllByLabelText('Title/Role').eq(0).type('Actuary Contact Title') cy.findAllByLabelText('Email').eq(0).type('actuarycontact@example.com') cy.findAllByLabelText('Mercer').eq(0).safeClick() + cy.findAllByLabelText( + "OACT can communicate directly with the state's actuaries but should copy the state on all written communication and all appointments for verbal discussions." + ).eq(0).safeClick() // Upload a rate certification and rate supporting document cy.findAllByTestId('file-input-input').each(fileInput => @@ -446,6 +449,14 @@ Cypress.Commands.add('fillOutAmendmentToPriorRateCertification', (id = 0) => { cy.findAllByLabelText('Title/Role').eq(0).type('Actuary Contact Title') cy.findAllByLabelText('Email').eq(0).type('actuarycontact@example.com') cy.findAllByLabelText('Mercer').eq(0).safeClick() + cy.findByRole('radiogroup', { + name: /Actuaries' communication preference/ + }) + .should('exist') + .within(() => { + cy.findByText("OACT can communicate directly with the state's actuaries but should copy the state on all written communication and all appointments for verbal discussions.") + .click() + }) // Upload a rate certification and rate supporting document cy.findAllByTestId('file-input-input').each(fileInput => @@ -484,7 +495,7 @@ Cypress.Commands.add('fillOutAdditionalActuaryContact', () => { // Actuary communication preference cy.findByText( - `OACT can communicate directly with the state’s actuaries but should copy the state on all written communication and all appointments for verbal discussions.` + "OACT can communicate directly with the state’s actuaries but should copy the state on all written communication and all appointments for verbal discussions." ).click() cy.findAllByTestId('errorMessage').should('have.length', 0) })