You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
VED-1049: Make invalid -immunization.target behaviour consistent in the search API (#1235)
* Better FHIR search functionality to handle invalid immunization targets
- Added support for `invalid_immunization_targets` in `FhirController` and `FhirService`.
- Updated `process_immunization_target` to return both valid and invalid vaccine types.
- Modified `validate_and_retrieve_search_params` to include invalid targets in the search parameters.
- Implemented logic to include an `OperationOutcome` in the response when invalid targets are provided.
- Updated tests to cover scenarios for invalid immunization targets and ensure correct handling in search results.
* Empty-Commit
* Rename test method to clarify error handling for invalid immunization targets
* Refactor search parameter validation to return structured results
- Updated `validate_and_retrieve_search_params` to return a `SearchParamsResult` object, encapsulating both valid parameters and invalid immunization targets.
- Adjusted `_search_immunizations` method in `FhirController` to utilize the new result structure.
- Modified tests to reflect changes in the validation function and ensure correct handling of search parameters.
* Implement smoke tests for Search API with mixed valid and invalid Disease Types
- Added a new scenario to verify that the Search API returns a 200 status code with results and an OperationOutcome when both valid and invalid Disease Types are provided.
- Implemented corresponding step definitions for GET and POST requests to handle mixed Disease Types.
- Better validation to ensure the response includes search results and appropriate OperationOutcome for invalid immunization targets.
* ruff fix
* more ruff fixes
* ruff fix
* ruff fixes
diagnostics=f"Your search included invalid -immunization.target value(s) that were ignored: {invalid_list}. The search was performed using the valid value(s) only.",
0 commit comments