EDS Test Scripts
0.1.0 - ci-build Denmark flag

EDS Test Scripts, published by MedCom. This guide is not an authorized publication; it is the continuous build for version 0.1.0 built by the FHIR (HL7® FHIR® Standard) CI Build. This version is based on the current content of https://github.com/medcomdk/dk-ehmi-eds-testscripts/ and changes regularly. See the Directory of published versions

TestScript: Test for ANS.4 - Organization Searching

Official URL: http://medcomehmi.dk/ig/edstestscripts/ANS4TestOrgSearch Version: 0.1.0
Active as of 2025-08-18 Computable Name: ANS4TestOrgSearch

Copyright/Legal: MedCom 2025

Profile: http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript

url: TestScript ANS4TestOrgSearch

version: 0.1.0

name: ANS4TestOrgSearch

status: Aktiv

date: 2025-08-18

publisher: MedCom

contact: MedCom: https://medcom.dk,ehmi@medcom.dk

jurisdiction: Denmark

copyright:

MedCom 2025

Origins

-IndexProfile
*1Test script profile origin type FHIR-Client: FHIR Client

Destinations

-IndexProfile
*1Test script profile destination type FHIR-Server: FHIR Server

fixture

id

C1EUAEDSPatientDeliveryStatus

autocreate: false

autodelete: false

resource: ./Fixtures/AuditEvent-C1EUAToEdsFixture.json

profile: http://medcomehmi.dk/ig/eds/StructureDefinition/EdsPatientDeliveryStatus

variable

name: IdOfResourceToBeCreated

expression: id

sourceId: C1EUAEDSPatientDeliveryStatus

variable

name: SORIDOfReceiverOrganization

expression: agent.where(type.coding.code = 'ehmiReceiver').who.identifier.value

sourceId: C1EUAEDSPatientDeliveryStatus

variable

name: GLNOfReceiverOrganization

expression: agent.where(type.coding.code = 'ehmiReceiver').extension.where(url = 'http://medcomehmi.dk/ig/eds/StructureDefinition/eds-otherId').valueIdentifier.value

sourceId: C1EUAEDSPatientDeliveryStatus

variable

name: NameReceiverOrganization

expression: agent.where(type.coding.code = 'ehmiReceiver').name

sourceId: C1EUAEDSPatientDeliveryStatus

variable

name: SORIDOfSenderOrganization

expression: agent.where(type.coding.code = 'ehmiSender').who.identifier.value

sourceId: C1EUAEDSPatientDeliveryStatus

variable

name: GLNOfSenderOrganization

expression: agent.where(type.coding.code = 'ehmiSender').extension.where(url = 'http://medcomehmi.dk/ig/eds/StructureDefinition/eds-otherId').valueIdentifier.value

sourceId: C1EUAEDSPatientDeliveryStatus

variable

name: NameSenderOrganization

expression: agent.where(type.coding.code = 'ehmiSender').name

sourceId: C1EUAEDSPatientDeliveryStatus

setup

action

Operations

-TypeResourceDescriptionDestinationEncodeRequestUrlOriginParams
*Test script operation code delete: DeleteAuditEventDeletes the resource we intend to create later, to ensure it doesn't already exist on the server from previously run tests1true1/${IdOfResourceToBeCreated}

test

id

CreatePatientDeliveryStatus

name: ANS4 Create

description: Use case ANS4 create PatientDeliveryStatus object on the SUT in order to search for it later

action

Operations

-TypeResourceDescriptionDestinationEncodeRequestUrlOriginParamsSourceId
*Test script operation code update: UpdateAuditEventCreate a PatientDeliveryStatus AuditEvent resource on the SUT1true1/${IdOfResourceToBeCreated}C1EUAEDSPatientDeliveryStatus

action

Asserts

-DescriptionDirectionResponseWarningOnly
*Ensure the PatientDeliveryStatus AuditEvent was createdresponsecreatedfalse

test

id

SearchPatientDeliveryStatusWithReceiverOrgSOR

name: ANS4 receiver org search SOR

description: Use case ANS4 search for the created PatientDeliveryStatus object on the SUT with receiver org SOR

action

Operations

-TypeResourceDescriptionDestinationEncodeRequestUrlOriginParams
*Test script operation code search: SearchAuditEventSearch for the PatientDeliveryStatus AuditEvent with the receiver organization, SOR1true1?receiverOrg=${SORIDOfReceiverOrganization}

action

Asserts

-DescriptionDirectionExpressionOperatorValueWarningOnly
*Ensure the PatientDeliveryStatus AuditEvent is foundresponseBundle.entry.where(resource.resourceType = 'AuditEvent' and resource.id = '${IdOfResourceToBeCreated}').count()equals1false

test

id

SearchPatientDeliveryStatusWithReceiverOrgGLN

name: ANS4 receiver org search GLN

description: Use case ANS4 search for the created PatientDeliveryStatus object on the SUT with receiver org GLN

action

Operations

-TypeResourceDescriptionDestinationEncodeRequestUrlOriginParams
*Test script operation code search: SearchAuditEventSearch for the PatientDeliveryStatus AuditEvent with the receiver organization GLN1true1?receiverOrg=${GLNOfReceiverOrganization}

action

Asserts

-DescriptionDirectionExpressionOperatorValueWarningOnly
*Ensure the PatientDeliveryStatus AuditEvent is foundresponseBundle.entry.where(resource.resourceType = 'AuditEvent' and resource.id = '${IdOfResourceToBeCreated}').count()equals1false

test

id

SearchPatientDeliveryStatusWithReceiverOrgName

name: ANS4 receiver org search Name

description: Use case ANS4 search for the created PatientDeliveryStatus object on the SUT with receiver org Name

action

Operations

-TypeResourceDescriptionDestinationEncodeRequestUrlOriginParams
*Test script operation code search: SearchAuditEventSearch for the PatientDeliveryStatus AuditEvent with the receiver organization, Name1true1?receiverOrg=${NameReceiverOrganization}

action

Asserts

-DescriptionDirectionExpressionOperatorValueWarningOnly
*Ensure the PatientDeliveryStatus AuditEvent is foundresponseBundle.entry.where(resource.resourceType = 'AuditEvent' and resource.id = '${IdOfResourceToBeCreated}').count()equals1false

test

id

SearchPatientDeliveryStatusInvalidReceiverOrgDetails

name: ANS4 invalid receiver org search

description: Use case ANS4 search for the created PatientDeliveryStatus object on the SUT with an invalid receiver organization. Not expecting to find it

action

Operations

-TypeResourceDescriptionDestinationEncodeRequestUrlOriginParams
*Test script operation code search: SearchAuditEventSearch for the PatientDeliveryStatus AuditEvent with an invalid receiver organization1true1?receiverOrg=invalid

action

Asserts

-DescriptionDirectionExpressionOperatorValueWarningOnly
*Ensure the PatientDeliveryStatus AuditEvent is not found with an invalid receiver organizationresponseBundle.totalequals0false

test

id

SearchPatientDeliveryStatusWithSenderOrgSOR

name: ANS4 sender org search SOR

description: Use case ANS4 search for the created PatientDeliveryStatus object on the SUT with sender org SOR

action

Operations

-TypeResourceDescriptionDestinationEncodeRequestUrlOriginParams
*Test script operation code search: SearchAuditEventSearch for the PatientDeliveryStatus AuditEvent with the sender organization, SOR1true1?senderOrg=${SORIDOfSenderOrganization}

action

Asserts

-DescriptionDirectionExpressionOperatorValueWarningOnly
*Ensure the PatientDeliveryStatus AuditEvent is foundresponseBundle.entry.where(resource.resourceType = 'AuditEvent' and resource.id = '${IdOfResourceToBeCreated}').count()equals1false

test

id

SearchPatientDeliveryStatusWithSenderOrgGLN

name: ANS4 sender org search GLN

description: Use case ANS4 search for the created PatientDeliveryStatus object on the SUT with sender org GLN

action

Operations

-TypeResourceDescriptionDestinationEncodeRequestUrlOriginParams
*Test script operation code search: SearchAuditEventSearch for the PatientDeliveryStatus AuditEvent with the sender organization GLN1true1?senderOrg=${GLNOfSenderOrganization}

action

Asserts

-DescriptionDirectionExpressionOperatorValueWarningOnly
*Ensure the PatientDeliveryStatus AuditEvent is foundresponseBundle.entry.where(resource.resourceType = 'AuditEvent' and resource.id = '${IdOfResourceToBeCreated}').count()equals1false

test

id

SearchPatientDeliveryStatusWithSenderOrgName

name: ANS4 sender org search name

description: Use case ANS4 search for the created PatientDeliveryStatus object on the SUT with sender org Name

action

Operations

-TypeResourceDescriptionDestinationEncodeRequestUrlOriginParams
*Test script operation code search: SearchAuditEventSearch for the PatientDeliveryStatus AuditEvent with the sender organization, Name1true1?senderOrg=${NameSenderOrganization}

action

Asserts

-DescriptionDirectionExpressionOperatorValueWarningOnly
*Ensure the PatientDeliveryStatus AuditEvent is foundresponseBundle.entry.where(resource.resourceType = 'AuditEvent' and resource.id = '${IdOfResourceToBeCreated}').count()equals1false

test

id

SearchPatientDeliveryStatusInvalidSenderOrgDetails

name: ANS4 invalid search

description: Use case ANS4 search for the created PatientDeliveryStatus object on the SUT with an invalid sender organization. Not expecting to find it

action

Operations

-TypeResourceDescriptionDestinationEncodeRequestUrlOriginParams
*Test script operation code search: SearchAuditEventSearch for the PatientDeliveryStatus AuditEvent with an invalid sender organization1true1?senderOrg=invalid

action

Asserts

-DescriptionDirectionExpressionOperatorValueWarningOnly
*Ensure the PatientDeliveryStatus AuditEvent is not found with an invalid sender organizationresponseBundle.totalequals0false