diff --git a/e2e/fixtures/testFixture.ts b/e2e/fixtures/testFixture.ts index 7fa2a1721..4df371d02 100644 --- a/e2e/fixtures/testFixture.ts +++ b/e2e/fixtures/testFixture.ts @@ -34,7 +34,7 @@ export type SBLPlaywrightTest = TestType< navigateToReviewWarningsAfterOnlyWarningsUpload: Page; navigateToSyntaxErrorsAfterSyntaxErrorsUpload: Page; navigateToLogicErrorsAfterLogicErrorsUpload: Page; - navigateToProvidePointOfContact: Page; + navigateToProvideFilingDetails: Page; navigateToSignAndSubmit: Page; }, PlaywrightWorkerArgs & PlaywrightWorkerOptions @@ -51,7 +51,7 @@ export const test = baseTest.extend<{ navigateToReviewWarningsAfterOnlyWarningsUpload: Page; navigateToSyntaxErrorsAfterSyntaxErrorsUpload: Page; navigateToLogicErrorsAfterLogicErrorsUpload: Page; - navigateToProvidePointOfContact: Page; + navigateToProvideFilingDetails: Page; navigateToSignAndSubmit: Page; }>({ isNonAssociatedUser: [false, { option: true }], // Default is 'false' @@ -317,7 +317,7 @@ export const test = baseTest.extend<{ }); }, - navigateToProvidePointOfContact: async ( + navigateToProvideFilingDetails: async ( { page, navigateToReviewWarningsAfterOnlyWarningsUpload }, use, ) => { @@ -331,12 +331,15 @@ export const test = baseTest.extend<{ }, navigateToSignAndSubmit: async ( - { page, navigateToProvidePointOfContact }, + { page, navigateToProvideFilingDetails }, use, ) => { - navigateToProvidePointOfContact; + navigateToProvideFilingDetails; await test.step('Provide filing details: navigate to Sign and submit', async () => { - await test.step('Provide filing details: fill out form', async () => { + await test.step('Provide filing details: fill out voluntary reporter', async () => { + await page.getByText('Voluntary reporter', { exact: true }).click(); + }); + await test.step('Provide filing details: fill out contact', async () => { await page.getByLabel('First name').fill(pointOfContactJson.first_name); await page.getByLabel('Last name').fill(pointOfContactJson.last_name); await page diff --git a/e2e/pages/filing-app/point-of-contact/checkPocFormErrors.spec.ts b/e2e/pages/filing-app/filing-details/checkPocFormErrors.spec.ts similarity index 97% rename from e2e/pages/filing-app/point-of-contact/checkPocFormErrors.spec.ts rename to e2e/pages/filing-app/filing-details/checkPocFormErrors.spec.ts index c89f838e0..0d32914e2 100644 --- a/e2e/pages/filing-app/point-of-contact/checkPocFormErrors.spec.ts +++ b/e2e/pages/filing-app/filing-details/checkPocFormErrors.spec.ts @@ -15,9 +15,9 @@ import { clickContinueNext } from '../../../utils/navigation.utils'; test('Point of Contact: Checking for form errors based on user input', async ({ page, - navigateToProvidePointOfContact, + navigateToProvideFilingDetails, }) => { - navigateToProvidePointOfContact; + navigateToProvideFilingDetails; await test.step('Point of Contact: Check that the error header render when no input is filled', async () => { await clickContinueNext(test, page); @@ -50,9 +50,9 @@ test('Point of Contact: Checking for form errors based on user input', async ({ test('Point of Contact: Checking for unicode tolerance based on user input', async ({ page, - navigateToProvidePointOfContact, + navigateToProvideFilingDetails, }) => { - navigateToProvidePointOfContact; + navigateToProvideFilingDetails; await test.step('Point of Contact: Check that the error header render when no input is filled', async () => { await clickContinueNext(test, page); diff --git a/e2e/pages/filing-app/filing-step-routing/errorsLogic.spec.ts b/e2e/pages/filing-app/filing-step-routing/errorsLogic.spec.ts index 2a1b3de96..0029bd220 100644 --- a/e2e/pages/filing-app/filing-step-routing/errorsLogic.spec.ts +++ b/e2e/pages/filing-app/filing-step-routing/errorsLogic.spec.ts @@ -5,7 +5,7 @@ const testLabel = 'Filing step routing (Errors: Logic)'; const currentStepPath = '/error'; -const userShouldNotAccess = ['/warnings', '/contact', '/submit']; +const userShouldNotAccess = ['/warnings', '/details', '/submit']; const afterRedirectHeading = 'Resolve errors (syntax)'; const afterRedirectURL = /.*errors\/errors-syntax$/; diff --git a/e2e/pages/filing-app/filing-step-routing/errorsSyntax.spec.ts b/e2e/pages/filing-app/filing-step-routing/errorsSyntax.spec.ts index fc782ff97..1c3071cda 100644 --- a/e2e/pages/filing-app/filing-step-routing/errorsSyntax.spec.ts +++ b/e2e/pages/filing-app/filing-step-routing/errorsSyntax.spec.ts @@ -8,7 +8,7 @@ const currentStepPath = '/error'; const userShouldNotAccess = [ '/errors/errors-logic', '/warnings', - '/contact', + '/details', '/submit', ]; diff --git a/e2e/pages/filing-app/filing-step-routing/noUpload.spec.ts b/e2e/pages/filing-app/filing-step-routing/noUpload.spec.ts index 5dd71bb23..f5ea7d920 100644 --- a/e2e/pages/filing-app/filing-step-routing/noUpload.spec.ts +++ b/e2e/pages/filing-app/filing-step-routing/noUpload.spec.ts @@ -5,7 +5,7 @@ const testLabel = 'Filing step routing (Upload)'; const currentStepPath = '/upload'; -const userShouldNotAccess = ['/errors', '/warnings', '/contact', '/submit']; +const userShouldNotAccess = ['/errors', '/warnings', '/details', '/submit']; const afterRedirectHeading = 'Upload file'; const afterRedirectURL = /.*\/upload$/; diff --git a/e2e/pages/filing-app/filing-step-routing/pointOfContact.spec.ts b/e2e/pages/filing-app/filing-step-routing/pointOfContact.spec.ts index aae1b6f15..a3b90b695 100644 --- a/e2e/pages/filing-app/filing-step-routing/pointOfContact.spec.ts +++ b/e2e/pages/filing-app/filing-step-routing/pointOfContact.spec.ts @@ -3,15 +3,15 @@ import { verifyRedirects } from './_shared'; const testLabel = 'Filing step routing (Point of Contact)'; -const currentStepPath = '/contact'; +const currentStepPath = '/details'; const userShouldNotAccess = ['/submit']; const afterRedirectHeading = 'Provide filing details'; -const afterRedirectURL = /.*\/contact$/; +const afterRedirectURL = /.*\/details$/; -test(testLabel, async ({ page, navigateToProvidePointOfContact }) => { - navigateToProvidePointOfContact; +test(testLabel, async ({ page, navigateToProvideFilingDetails }) => { + navigateToProvideFilingDetails; await verifyRedirects({ testLabel, diff --git a/e2e/pages/filing-app/filing-step-routing/warnings.spec.ts b/e2e/pages/filing-app/filing-step-routing/warnings.spec.ts index 941adcb22..fc6e8b847 100644 --- a/e2e/pages/filing-app/filing-step-routing/warnings.spec.ts +++ b/e2e/pages/filing-app/filing-step-routing/warnings.spec.ts @@ -5,7 +5,7 @@ const testLabel = 'Filing step routing (Warnings)'; const currentStepPath = '/warnings'; -const userShouldNotAccess = ['/contact', '/submit']; +const userShouldNotAccess = ['/details', '/submit']; const afterRedirectHeading = 'Review warnings'; const afterRedirectURL = /.*\/warnings$/; diff --git a/e2e/pages/filing-app/formAlerts.spec.ts b/e2e/pages/filing-app/formAlerts.spec.ts index 833fc3d1b..03056fffa 100644 --- a/e2e/pages/filing-app/formAlerts.spec.ts +++ b/e2e/pages/filing-app/formAlerts.spec.ts @@ -186,8 +186,8 @@ test('Form Alerts', async ({ await clickContinueNext(test, page); }); - // Point of contact page - await test.step('Point of contact page', async () => { + // Filing details page + await test.step('Filing details page', async () => { await expect(page.locator('h1'), 'h1 is correct').toContainText( 'Provide filing details', ); @@ -199,7 +199,7 @@ test('Form Alerts', async ({ page.locator('.m-notification__error'), 'Error alert is visible', ).toContainText( - 'There was a problem updating your filing detailsEnter the first name of the point of contactEnter the last name of the point of contactEnter the phone number of the point of contactEnter the email address of the point of contactEnter the street address of the point of contactEnter the city of the point of contactSelect the state or territory of the point of contactEnter the ZIP code of the point of contact', + 'There was a problem updating your filing detailsIndicate your voluntary reporter statusEnter the first name of the point of contactEnter the last name of the point of contactEnter the phone number of the point of contactEnter the email address of the point of contactEnter the street address of the point of contactEnter the city of the point of contactSelect the state or territory of the point of contactEnter the ZIP code of the point of contact', ); }); diff --git a/src/App.tsx b/src/App.tsx index 0f2d371cf..8fc9992e1 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -14,7 +14,7 @@ import Error500 from 'pages/Error/Error500'; import { NotFound404 } from 'pages/Error/NotFound404'; import FileSubmission from 'pages/Filing/FilingApp/FileSubmission'; import FilingComplete from 'pages/Filing/FilingApp/FilingComplete'; -import FilingContact from 'pages/Filing/FilingApp/FilingContact'; +import FilingDetails from 'pages/Filing/FilingApp/FilingDetails'; import FilingErrors from 'pages/Filing/FilingApp/FilingErrors'; import FilingOverview from 'pages/Filing/FilingApp/FilingOverviewPage'; import FilingProtectedRoute from 'pages/Filing/FilingApp/FilingProtectedRoute'; @@ -308,13 +308,13 @@ export default function App(): ReactElement { } /> - + diff --git a/src/components/CommonLinks.tsx b/src/components/CommonLinks.tsx index 2c89182b4..2da63c544 100644 --- a/src/components/CommonLinks.tsx +++ b/src/components/CommonLinks.tsx @@ -42,21 +42,21 @@ function UpdateInstitutionProfile({ UpdateInstitutionProfile.defaultProps = { isCallToAction: false }; -interface UpdatePointOfContactProperties { +interface UpdateFilingDetailsProperties { // eslint-disable-next-line react/require-default-props label?: string; // eslint-disable-next-line react/require-default-props, react/no-unused-prop-types className?: string; } -function UpdatePointOfContact({ +function UpdateFilingDetails({ label = 'update your filing details', className = 'font-normal', -}: UpdatePointOfContactProperties): ReactElement { +}: UpdateFilingDetailsProperties): ReactElement { const { lei, year } = useParams(); const navigate = useNavigate(); - const onClick = (): void => navigate(`/filing/${year}/${lei}/contact`); + const onClick = (): void => navigate(`/filing/${year}/${lei}/details`); return (