Skip to content

LG-10464 FSM/Address Get route and controller#9377

Merged
svalexander merged 16 commits intomainfrom
shannon/lg-10464-get-route-address
Oct 26, 2023
Merged

LG-10464 FSM/Address Get route and controller#9377
svalexander merged 16 commits intomainfrom
shannon/lg-10464-get-route-address

Conversation

@svalexander
Copy link
Contributor

@svalexander svalexander commented Oct 13, 2023

🎫 Ticket

LG-10464

🛠 Summary of changes

Add get route and controller for residential address page.

Things to note:

  • Analytics arguments in visited event does not include same_address_as_id
  • Submitted event will be logged on submission w/ update route and so is not present in this pr
  • City field is not being validated currently, this should be rectified w/ addition of update route
  • Can't continue on to ssn page

📜 Testing Plan

Provide a checklist of steps to confirm the changes.

  • Go through ipp flow and arrive at state id page
  • select no address does not match id
  • click continue and make sure url is in_person/address
  • Change url manually to in_person_proofing/address and make sure 404 renders
  • In config/application.yml.default update controller flag (in_person_residential_address_controller_enabled) to true
  • Go through ipp flow again and arrive at state id page
  • select no address does not match id
  • Continue to next page and make sure url is in_person_proofing/address
  • Make sure step indicator at top of page has find a post office checked complete
  • Make sure step indicator at top of page has verify your information as current step
  • Check that event log has in person proofing address visited event with analytics arguments
  • Click Cancel and make sure it takes you to /verify/cancel?step=address
  • Click "no..." and return to address page
  • Click continue and see that you don't proceed to ssn page as update route isn't present

@svalexander svalexander marked this pull request as draft October 13, 2023 14:08
@svalexander svalexander changed the title add routes, view and controller LG-10464 FSM/Address Get route and controller Oct 20, 2023
@svalexander svalexander marked this pull request as ready for review October 20, 2023 21:17
RSpec.describe Idv::InPerson::AddressController do
include InPersonHelper
let(:in_person_residential_address_controller_enabled) { true }
let(:pii_from_user) do
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Will update constants.rb to include a mock applicant that has these fields

@svalexander svalexander requested review from a team and allthesignals October 23, 2023 19:53
@gina-yamada
Copy link
Contributor

gina-yamada commented Oct 24, 2023

I tested when flag was disabled. I am not able to get to page when I type in the non-FSM URL. I go to the FSM url, which is what I'd expect. I tested when the flag was enabled. I am able to hit the new view/controller/route. View (visiting first time only) is working as expected. Validation before submit is working and I see Puerto Rico hints on the form. New url is what I'd expect.

I reviewed at my PR for this similar issue. Maybe consider adding some features tests in a new file- spec/features/idv/steps/in_person/address_spec (or maybe these go somewhere else better). I would just add when the flag is enabled. We can delete "when the flag is enabled" later and keep all of the specs. ie: When you click cancel and then start over, when you click cancel and keep going (testing flow). When you visit the new controller for the first time- what does the heading and button display? (testing text on new view- both change if it is initial visit or on edit.)

I agree with Sonia's comments above about marking the FSM step as complete. I think this is pretty close. Poke me if/when you want another review.

Copy link
Contributor

@gina-yamada gina-yamada left a comment

Choose a reason for hiding this comment

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

The new view & controller are working as I'd expect. Thanks for adding those additional tests in this PR. I think the more tests we can add the better. I tested the FSM flow a lot (flag is disabled). I can not any place that your changes have affected it- and that is what we want at this stage.

@svalexander svalexander merged commit d9b6588 into main Oct 26, 2023
@svalexander svalexander deleted the shannon/lg-10464-get-route-address branch October 26, 2023 17: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.

3 participants