Skip to content

Conversation

@Binayak490-cyber
Copy link

This PR enhances PatientValidator to ensure that a patient must have identifiers for all required and non-retired PatientIdentifierTypes before validation passes.

Changes included:

Added validation logic to check that every required, non-retired identifier type has a corresponding non-voided patient identifier.

Updated and added unit tests to cover the following scenarios:

Patient missing a required identifier (validation fails)

Patient with required identifier present (validation passes)

Required identifier is voided (validation fails)

Required identifier type is retired (validation ignored)

This change ensures data consistency and aligns patient validation with the configured identifier requirements.All tests pass locally.

@sonarqubecloud
Copy link

@Binayak490-cyber
Copy link
Author

Hi @ibacher,

This PR addresses TRUNK-6529 by ensuring that a patient must have identifiers for all required, non-retired PatientIdentifierTypes before validation passes.

I’ve added validation logic and updated unit tests to cover missing, present, voided, and retired required identifiers.

All tests pass locally (mvn clean test).

Please review when convenient.Thanks!

@Binayak490-cyber
Copy link
Author

Hi @ibacher,
Just a gentle reminder regarding this PR for TRUNK-6529: Ensure patient has all required identifiers.
The fix ensures validation for required patient identifiers and all tests are passing.
Please let me know if any changes or improvements are needed from my side.

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.

1 participant