-
Notifications
You must be signed in to change notification settings - Fork 35
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #12984 from transcom/B-20010-INT
B 20010 int Add FF for HQ role
- Loading branch information
Showing
20 changed files
with
81 additions
and
80 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -90,10 +90,6 @@ describe('RequestAccountForm component', () => { | |
const qsaCheckbox = screen.getByTestId('qualityAssuranceEvaluatorCheckBox'); | ||
expect(qsaCheckbox).toBeInstanceOf(HTMLInputElement); | ||
expect(qsaCheckbox).not.toBeChecked(false); | ||
|
||
const hqCheckbox = screen.getByTestId('headquartersCheckBox'); | ||
expect(hqCheckbox).toBeInstanceOf(HTMLInputElement); | ||
expect(hqCheckbox).not.toBeChecked(false); | ||
}); | ||
|
||
it('cancels requesting office account when cancel button is clicked', async () => { | ||
|
@@ -149,51 +145,6 @@ describe('RequestAccountForm component', () => { | |
expect(testProps.onSubmit).toHaveBeenCalled(); | ||
}); | ||
|
||
it('submits Headquarters office account form when submit button is clicked', async () => { | ||
const mockOfficeId = '3210a533-19b8-4805-a564-7eb452afce10'; | ||
const mockHeadquartersOffice = { | ||
address: { | ||
city: 'Test City', | ||
country: 'United States', | ||
id: 'a13806fc-0e7d-4dc3-91ca-b802d9da50f1', | ||
postalCode: '85309', | ||
state: 'AZ', | ||
streetAddress1: '7383 N Litchfield Rd', | ||
streetAddress2: 'Rm 1122', | ||
}, | ||
created_at: '2018-05-28T14:27:39.198Z', | ||
gbloc: 'KKFA', | ||
id: mockOfficeId, | ||
name: 'Tester', | ||
phone_lines: [], | ||
updated_at: '2018-05-28T14:27:39.198Z', | ||
}; | ||
|
||
const mockSearchHeadquartersOfficesOpen = () => Promise.resolve([mockHeadquartersOffice]); | ||
searchTransportationOfficesOpen.mockImplementation(mockSearchHeadquartersOfficesOpen); | ||
|
||
renderWithRouter(<RequestAccountForm {...testProps} />); | ||
|
||
await userEvent.type(screen.getByLabelText('First Name'), 'Bob'); | ||
await userEvent.type(screen.getByLabelText('Last Name'), 'Banks'); | ||
await userEvent.type(screen.getByLabelText('Email'), '[email protected]'); | ||
await userEvent.type(screen.getByLabelText('Telephone'), '333-333-3333'); | ||
await userEvent.type(screen.getByTestId('officeAccountRequestEdipi'), '1111111111'); | ||
await userEvent.type(screen.getByTestId('officeAccountRequestOtherUniqueId'), '1111111111'); | ||
|
||
const transportationOfficeInput = screen.getByLabelText('Transportation Office'); | ||
fireEvent.change(transportationOfficeInput, { target: { value: 'Tester' } }); | ||
await act(() => selectEvent.select(transportationOfficeInput, /Tester/)); | ||
|
||
const tooCheckbox = screen.getByTestId('headquartersCheckBox'); | ||
await userEvent.click(tooCheckbox); | ||
|
||
const submitButton = await screen.getByTestId('requestOfficeAccountSubmitButton'); | ||
await userEvent.click(submitButton); | ||
|
||
expect(testProps.onSubmit).toHaveBeenCalled(); | ||
}); | ||
|
||
it('shows policy error when both TOO and TIO checkboxes are both selected, and goes away after unselecting one of them', async () => { | ||
renderWithRouter(<RequestAccountForm {...testProps} />); | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters