Skip to content

Jryan/lg 12172 tmx rejection screen#10116

Closed
JackRyan1989 wants to merge 37 commits intomainfrom
jryan/lg-12172-tmx-rejection-screen
Closed

Jryan/lg 12172 tmx rejection screen#10116
JackRyan1989 wants to merge 37 commits intomainfrom
jryan/lg-12172-tmx-rejection-screen

Conversation

@JackRyan1989
Copy link
Contributor

🎫 Ticket

Link to the relevant ticket:
LG-12172

🛠 Summary of changes

This simplifies and extends the logic used to implement LG-119955. The reason I could simplify is that we're targeting both reject and review methods instead of just one. So there's no need to isolate as much code.

📜 Testing Plan

  • Fire up the local server
  • Create a new user - make sure to hang on to the mock login info you use to create the account
  • Proceed through the IPP flow
  • On SSN page use the drop down to select Reject
  • Proceed through the rest of the flow to the barcode page to create the enrollment
  • Code comment out enrollment_outcomes[:enrollments_passed] += 1 from app/jobs/get_usps_proofing_results_job.rb
  • Open the rails console: rails c
  • Save the latest enrollment you just created: e = InPersonEnrollment.last
  • Create a new mock JSON blob: json = UspsInPersonProofing::Mock::Fixtures.request_passed_proofing_results_response
  • Save that response as a response: res = JSON.parse(json)
  • Update the user's profile: e.profile.update!(fraud_pending_reason: 2)
  • Initiate job: GetUspsProofingResultsJob.new.send(:process_enrollment_response, e, res)
  • Update the user: User.last.pending_profile.reject_for_fraud(notify_user: false)
  • Reload the enrollment: e.reload
  • Login again, and attempt to navigate past the /account page
  • You should end up on the /not_verified page

Test with a failed enrollment:

  • Fire up the local server
  • Create a new user - make sure to hang on to the mock login info you use to create the account
  • Proceed through the IPP flow
  • On SSN page use the drop down to select Reject
  • Proceed through the rest of the flow to the barcode page to create the enrollment
  • Code comment out enrollment_outcomes[:enrollments_failed] += 1 from app/jobs/get_usps_proofing_results_job.rb
  • Open the rails console: rails c
  • Save the latest enrollment you just created: e = InPersonEnrollment.last
  • Create a new mock JSON blob: json = UspsInPersonProofing::Mock::Fixtures.request_failed_proofing_results_response
  • Save that response as a response: res = JSON.parse(json)
  • Update the user's profile: e.profile.update!(fraud_pending_reason: 2)
  • Initiate job: GetUspsProofingResultsJob.new.send(:process_enrollment_response, e, res)
  • Update the user: User.last.pending_profile.reject_for_fraud(notify_user: false)
  • Reload the enrollment: e.reload
  • Login again, and attempt to navigate past the /account page
  • You should not hit the not verified page with a failed enrollment

JackRyan1989 added 30 commits January 30, 2024 17:02
…t a pending ipp enrollment exists for please call
…se call page when flagged for fraud review
…se call page when flagged for fraud review
…5-threatmetrix-please-call-ipp-screen

Pull in main to fix pinpoint check and js errors.
…le_pending_fraud_review on users with ipp enrollments
JackRyan1989 added 6 commits February 12, 2024 14:34
…5-threatmetrix-please-call-ipp-screen

Merging in main to get pinpoint checks to pass.
…o jryan/lg-12172-tmx-rejection-screen

Merging in work from LG-11995 to have access to fraud review changes and
new user method.
@JackRyan1989 JackRyan1989 requested review from a team and svalexander February 20, 2024 19:51
@JackRyan1989
Copy link
Contributor Author

Closing in favor of #10119

@JackRyan1989 JackRyan1989 deleted the jryan/lg-12172-tmx-rejection-screen branch February 20, 2024 21:46
@JackRyan1989 JackRyan1989 removed request for a team and svalexander February 20, 2024 21:46
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.

2 participants