-
Notifications
You must be signed in to change notification settings - Fork 4
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
Added fullUrl unique check to $extract #79
Conversation
{"linkId": "observationCode", "answer": [{"value": {"string": observationCode}}]}, | ||
{"linkId": "patientId", "answer": [{"value": {"string": PATINET_1_ID}}]}, | ||
{"linkId": "patientId2", "answer": [{"value": {"string": PATINET_2_ID}}]}, | ||
{"linkId": "observationCode", "answer": [{"value": {"string": OBSERVATION_CODE}}]}, | ||
], | ||
}, | ||
) | ||
|
||
with pytest.raises(OperationOutcome): | ||
await q.execute("$extract", data=qr) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You need to check the actual error
see an example:
with pytest.raises(OperationOutcome) as excinfo:
await ....
assert get_by_path(excinfo.value.resource, ["issue", 0, "code"]) == 'mycode'
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
tests/sdc/test_extract.py
Outdated
] | ||
}, | ||
"status": "final", | ||
PATINET_1_ID = "patient1" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fix typos PATINET...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed
app/sdc/extract.py
Outdated
@@ -17,12 +19,16 @@ async def get_external_service_bundle(session, service, template, context): | |||
|
|||
|
|||
async def execute_mappers_bundles(client, mappers_bundles): | |||
flatted_mappers_bundles = list(flatten(bundle["entry"] for bundle in mappers_bundles)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
flattened is better word
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changed
No description provided.