Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

API-39899-update-zip-first-five-validations-for-coa #18341

Merged

Conversation

rockwellwindsor-va
Copy link
Contributor

@rockwellwindsor-va rockwellwindsor-va commented Sep 5, 2024

Summary

  • Updates/adds the conditional validations for zipfirstFive and state for changeOfAddress in line with ticket ACs
  • Updates/adds tests for scenarios

Related issue(s)

API-39899

Testing done

  • New code is covered by unit tests

Testing Notes

  • Sample changeOfAddress block to add to the 526 submission that can be altered
      "changeOfAddress": {
        "typeOfAddressChange": "TEMPORARY",
        "addressLine1": "10 Peach St",
        "addressLine2": "Unit 4",
        "addressLine3": "Room 1",
        "city": "Atlanta",
        "state": "GA",
        "country": "USA",
        "zipFirstFive": "42220",
        "zipLastFour": "9897",
        "dates": {
          "beginDate": "2023-06-04",
          "endDate": "2023-12-04"
        }
      },
  • the presence of zipFirstFive if the country is "USA" was already being enforced.
  • change the country (Brazil is one example you can use) and submit with a zipFirstFive should produce an error because of the inclusion of the zipFirstFive when the country is not 'USA' This has requirement been removed
  • with country set to 'USA' comment out the state value (with country set to something other then 'USA' commenting out state should not do anything)

What areas of the site does it impact?

modified:   modules/claims_api/app/controllers/concerns/claims_api/v2/disability_compensation_validation.rb
modified:   modules/claims_api/spec/lib/claims_api/v2/disability_compensation_validation_spec.rb

Acceptance criteria

  • I fixed|updated|added unit tests and integration tests for each feature (if applicable).
  • No error nor warning in the console.
  • Events are being sent to the appropriate logging solution
  • Documentation has been updated (link to documentation)
  • No sensitive information (i.e. PII/credentials/internal URLs/etc.) is captured in logging, hardcoded, or specs
  • Feature/bug has a monitor built into Datadog (if applicable)
  • If app impacted requires authentication, did you login to a local build and verify all authenticated routes work as expected
  • I added a screenshot of the developed feature

Requested Feedback

(OPTIONAL)What should the reviewers know in addition to the above. Is there anything specific you wish the reviewer to assist with. Do you have any concerns with this PR, why?

* Updates/adds validations for zipfirstFive
* Updates/adds tests for scenarios
 Changes to be committed:
	modified:   modules/claims_api/app/controllers/concerns/claims_api/v2/disability_compensation_validation.rb
	modified:   modules/claims_api/spec/lib/claims_api/v2/disability_compensation_validation_spec.rb
@va-vfs-bot va-vfs-bot temporarily deployed to API-39899-update-zip-first-five-validations-for-coa/main/main September 5, 2024 22:12 Inactive
@va-vfs-bot va-vfs-bot temporarily deployed to API-39899-update-zip-first-five-validations-for-coa/main/main September 5, 2024 23:39 Inactive
@rockwellwindsor-va rockwellwindsor-va added the claimsApi modules/claims_api label Sep 6, 2024
@rockwellwindsor-va rockwellwindsor-va marked this pull request as ready for review September 6, 2024 13:00
@rockwellwindsor-va rockwellwindsor-va requested a review from a team as a code owner September 6, 2024 13:00
@va-vfs-bot va-vfs-bot temporarily deployed to API-39899-update-zip-first-five-validations-for-coa/main/main September 6, 2024 13:02 Inactive
mchristiansonVA
mchristiansonVA previously approved these changes Sep 6, 2024
Copy link
Contributor

@mchristiansonVA mchristiansonVA left a comment

Choose a reason for hiding this comment

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

Tested locally and confirmed validations working as expected with appropriate error messages. Looks good to me!

@rockwellwindsor-va rockwellwindsor-va marked this pull request as draft September 9, 2024 20:59
@rockwellwindsor-va rockwellwindsor-va marked this pull request as ready for review September 9, 2024 21:11
@va-vfs-bot va-vfs-bot temporarily deployed to API-39899-update-zip-first-five-validations-for-coa/main/main September 9, 2024 21:28 Inactive
@rockwellwindsor-va rockwellwindsor-va marked this pull request as draft September 10, 2024 14:10
@rockwellwindsor-va rockwellwindsor-va marked this pull request as ready for review September 10, 2024 23:16
@rockwellwindsor-va rockwellwindsor-va marked this pull request as draft September 11, 2024 14:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants