-
Notifications
You must be signed in to change notification settings - Fork 4
NRL-1076 add integration and unit tests for accession number #771
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
Changes from all commits
d946923
4abb3e3
1754771
123f837
9c16a6c
19ad615
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||
|---|---|---|---|---|
|
|
@@ -77,7 +77,35 @@ Feature: Consumer - searchDocumentReference - Failure Scenarios | |||
| "display": "Invalid code system" | ||||
| }] | ||||
| }, | ||||
| "diagnostics": "Invalid type (The provided type system does not match the allowed types for this organisation)", | ||||
| "diagnostics": "The provided type does not match the allowed types for this organisation", | ||||
| "expression": ["type"] | ||||
| } | ||||
| """ | ||||
|
|
||||
| Scenario: Search rejects request with type they are not allowed to use | ||||
| Given the application 'DataShare' (ID 'z00z-y11y-x22x') is registered to access the API | ||||
| And the organisation 'RX898' is authorised to access pointer types: | ||||
| | system | value | | ||||
| | http://snomed.info/sct | 736253002 | | ||||
| When consumer 'RX898' searches for DocumentReferences using POST with request body: | ||||
| | key | value | | ||||
| | subject | 9278693472 | | ||||
| | type | http://snomed.info/sct\|887701000000100 | | ||||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Same as above, see: NRLF/tests/features/utils/data.py Line 66 in 309c88a
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. yeah its a parameter for the search request not creating a pointer
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. True, it's a search, ignore me |
||||
| Then the response status code is 400 | ||||
| And the response is an OperationOutcome with 1 issue | ||||
| And the OperationOutcome contains the issue: | ||||
| """ | ||||
| { | ||||
| "severity": "error", | ||||
| "code": "code-invalid", | ||||
| "details": { | ||||
| "coding": [{ | ||||
| "system": "https://fhir.nhs.uk/ValueSet/Spine-ErrorOrWarningCode-1", | ||||
| "code": "INVALID_CODE_SYSTEM", | ||||
| "display": "Invalid code system" | ||||
| }] | ||||
| }, | ||||
| "diagnostics": "The provided type does not match the allowed types for this organisation", | ||||
| "expression": ["type"] | ||||
| } | ||||
| """ | ||||
|
|
||||
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.
This might not be doing what you expect it to do. See:
NRLF/tests/features/utils/data.py
Line 66 in 309c88a
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.
I'm searching for pointers with that type as a parameter thats got nothing to do with creating a pointer of a certain type?
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.
True, it's a search, ignore me