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

FI-2687 Skip find search values from primitive extension #167

Merged
merged 2 commits into from
Apr 17, 2024

Conversation

yunwwang
Copy link
Contributor

@yunwwang yunwwang commented Apr 17, 2024

Summary

This fixes JIRA FHIR-2687. The problem happens when search parameter targets a primitive value and the resource has an extension on the primitive, for example, instead of

"date": "2024-01-01"

server pupulates date with extension:

"_date": {
  "extension": [ {
    "url": "http://example.com/extension",
    "valueString": "value"
  }]
}

When Infenro extract search values from returned resourcee, Inferno locates the primitive and tries to conver the "primitve value" into a string. When the value is actually an extension, as shown above, the to_s fails.

Change Logs:

  • Fix search_param_value method so that when the element is a type of Element is skip. This is based on that all search parameters target concrete data types. Data type Element is the base class and not used in any profile directly. The only usage in Inferno US Core test kit is when the navigator sees a primitive extension, it converts that into an Element with extension.
  • Add two unit tests to verify that search value is retrieved when primitive has extension
  • Update Dockerfile to run gem update before gem install

Testing Guidance

@yunwwang yunwwang requested a review from Jammjammjamm April 17, 2024 15:44
@yunwwang yunwwang merged commit 18aa7ca into main Apr 17, 2024
2 checks passed
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