Check if dataRequirement resourceType does not have patient search params #289
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
We found an issue when running
dataRequirements
with CMS68. It will error out with the Task resource on CMS68 since the Task resource type is in the compartment definition, but does not have any search parameters so it is not included inPatientParameters.ts
(the file that is a result of running theparseCompartmentDefiniton.js
script in thedeqm-test-server
repo). Now, runningdataRequirements
on this measure no longer errors out.New behavior
Now, we only do a
.forEach
on the indexed content of PatientParameters for a resourceType if that resourceType exists in PatientParameters.Code changes
DataRequirementsHelpers.ts
- skips adding an extension to a data requirement whose resourceType is not inPatientParameters.ts
.Testing guidance
npm run check
npm run test:integration
QUESTION: Should we be adding an extension to dataRequirements whose resourceType is not in
PatientParameters.ts
? I tried looking into the spec forfhirQueryPattern
but wasn't sure...