Name | /FHIRSandbox/DaVinci/FHIR4-0-1-PlanNetProvDir/Plan-Net-1-1-0/PlanNetProvDir-XML/03-Query/dv-pdex-r4-03-PlanNet-03-Query-07-organizationaffiliation-xml |
Description | Da Vinci - PDex - FHIR R4 - Scenario 03 PlanNet - Query - Search for all Organization Affliations and validate that they conform to the PlanNet OrganizationAffiliation profile. |
Version | 1 | Latest | 1 |
<?xml version="1.0" encoding="UTF-8"?>
<TestScript xmlns="http://hl7.org/fhir">
<id value="dv-pdex-r4-03-plannet-03-query-07-organizationaffiliation-xml"/>
<meta>
<profile value="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript"/>
</meta>
<text>
<status value="generated"/>
<div xmlns="http://www.w3.org/1999/xhtml">
<p>Da Vinci - PDex - FHIR R4 - 03 PlanNet - 03 Query - 07 Organization Affiliations - XML</p>
</div>
</text>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-rule">
<extension url="ruleId">
<valueId value="rule-validate-PDex-PlanNet"/>
</extension>
<extension url="path">
<valueString value="/FHIRCommon/_reference/rule/AssertValidateXMLExtractProfileId.groovy"/>
</extension>
<extension url="param">
<extension url="name">
<valueString value="xPath"/>
</extension>
<extension url="value">
<valueString value="(Bundle/entry/resource/OrganizationAffiliation)[1]"/>
</extension>
</extension>
<extension url="param">
<extension url="name">
<valueString value="profileId"/>
</extension>
<extension url="value">
<valueString value="PDex-PlanNet-OrganizationAffiliation-profile"/>
</extension>
</extension>
</extension>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-rule">
<extension url="ruleId">
<valueId value="rule-ReplaceNullVariable"/>
</extension>
<extension url="path">
<valueString value="/FHIRCommon/_reference/rule/ReplaceNullVariable.groovy"/>
</extension>
</extension>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-rule">
<extension url="ruleId">
<valueId value="rule-GetVariable-FhirPath"/>
</extension>
<extension url="path">
<valueString value="/FHIRCommon/_reference/rule/GetVariable-FhirPath.groovy"/>
</extension>
</extension>
<url value="http://wildfhir.aegis.net/fhir4-0-0/TestScript/dv-pdex-r4-03-plannet-03-query-07-organizationaffiliation-xml"/>
<name value="DaVinciPDexR403PlanNet03Query07OrganizationAffiliationXML"/>
<title value="Da Vinci - PDex - FHIR R4 - PlanNet - XML"/>
<status value="active"/>
<date value="2023-01-27"/>
<publisher value="AEGIS.net, Inc."/>
<contact>
<name value="Touchstone Support"/>
<telecom>
<system value="email"/>
<value value="Touchstone_Support@aegis.net"/>
<use value="work"/>
</telecom>
</contact>
<description value="Da Vinci - PDex - FHIR R4 - Scenario 03 PlanNet - Query - Search for all Organization Affliations and validate that they conform to the PlanNet OrganizationAffiliation profile."/>
<copyright value="This FHIR Test Script is licensed under Creative Commons (CC0) 'No Rights Reserved'. Learn more at https://creativecommons.org/licenses"/>
<origin id="SMART-on-FHIR App">
<index value="1"/>
<profile>
<system value="http://terminology.hl7.org/CodeSystem/testscript-profile-origin-types"/>
<code value="FHIR-Client"/>
</profile>
</origin>
<destination id="Payer FHIR Server">
<index value="1"/>
<profile>
<system value="http://terminology.hl7.org/CodeSystem/testscript-profile-destination-types"/>
<code value="FHIR-Server"/>
</profile>
</destination>
<profile id="bundle-profile">
<reference value="http://hl7.org/fhir/StructureDefinition/Bundle"/>
</profile>
<profile id="PDex-PlanNet-OrganizationAffiliation-profile">
<reference value="http://hl7.org/fhir/us/davinci-pdex-plan-net/StructureDefinition/plannet-OrganizationAffiliation"/>
</profile>
<variable>
<name value="primary-organizationValue"/>
<expression value="Bundle.entry.resource.organization.reference"/>
<sourceId value="searchResponse"/>
</variable>
<variable>
<name value="participating-organizationValue"/>
<expression value="Bundle.entry.resource.participatingOrganization.reference"/>
<sourceId value="searchResponse"/>
</variable>
<variable>
<name value="locationValue"/>
<expression value="Bundle.entry.resource.location.reference"/>
<sourceId value="searchResponse"/>
</variable>
<variable>
<name value="serviceValue"/>
<expression value="Bundle.entry.resource.healthcareService.reference"/>
<sourceId value="searchResponse"/>
</variable>
<variable>
<name value="networkValue"/>
<expression value="Bundle.entry.resource.network.reference"/>
<sourceId value="searchResponse"/>
</variable>
<variable>
<name value="endpointValue"/>
<expression value="Bundle.entry.resource.endpoint.reference"/>
<sourceId value="searchResponse"/>
</variable>
<variable>
<name value="roleValue"/>
<expression value="Bundle.entry.resource.code.coding.code"/>
<sourceId value="searchResponse"/>
</variable>
<variable>
<name value="specialtyValue"/>
<expression value="Bundle.entry.resource.specialty.coding.code"/>
<sourceId value="searchResponse"/>
</variable>
<variable>
<name value="resourceId"/>
<expression value="Bundle.entry.resource.id"/>
<sourceId value="searchResponse"/>
</variable>
<variable>
<name value="lastUpdatedValue"/>
<expression value="Bundle.entry.resource.meta.lastUpdated"/>
<sourceId value="searchResponse"/>
</variable>
<test id="01-Search-OrganizationAffiliations">
<name value="SearchOrganizationAffiliations"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<action>
<operation>
<type>
<system value="http://terminology.hl7.org/CodeSystem/testscript-operation-codes"/>
<code value="search"/>
</type>
<resource value="OrganizationAffiliation"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<accept value="xml"/>
<destination value="1"/>
<encodeRequestUrl value="true"/>
<origin value="1"/>
<params value="?_count=100"/>
<responseId value="searchResponse"/>
</operation>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the client requested an Accept of the FHIR XML mime type 'application/fhir+xml'."/>
<direction value="request"/>
<headerField value="Accept"/>
<operator value="contains"/>
<value value="application/fhir+xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the client did not request a Content-Type. Warning only to allow for systems that automatically send Content-Type."/>
<direction value="request"/>
<headerField value="Content-Type"/>
<operator value="empty"/>
<warningOnly value="true"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned HTTP status is 200(OK)."/>
<direction value="response"/>
<responseCode value="200"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned HTTP Header Content-Type is present."/>
<direction value="response"/>
<headerField value="Content-Type"/>
<operator value="notEmpty"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned HTTP Header Content-Type contains the FHIR mime-type 'application/fhir+xml'."/>
<direction value="response"/>
<contentType value="xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned resource type is Bundle."/>
<direction value="response"/>
<resource value="Bundle"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned Bundle type is searchset."/>
<direction value="response"/>
<operator value="equals"/>
<path value="Bundle/type"/>
<value value="searchset"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle conforms to the base FHIR specification."/>
<direction value="response"/>
<validateProfileId value="bundle-profile"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned Bundle has more than 0 entries"/>
<direction value="response"/>
<expression value="Bundle.entry.count()"/>
<operator value="greaterThan"/>
<value value="0"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-rule">
<extension url="ruleId">
<valueId value="rule-validate-PDex-PlanNet"/>
</extension>
</extension>
<description value="Validate PDex OrganizationAffiliation within the search Bundle."/>
<direction value="response"/>
<warningOnly value="false"/>
</assert>
</action>
</test>
<test id="02-Search-OrganizationAffiliations-by-primary-organization">
<name value="SearchOrganizationAffiliations-by-primary-organization"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<action>
<operation>
<type>
<system value="http://terminology.hl7.org/CodeSystem/testscript-operation-codes"/>
<code value="search"/>
</type>
<resource value="OrganizationAffiliation"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<accept value="xml"/>
<destination value="1"/>
<encodeRequestUrl value="true"/>
<origin value="1"/>
<params value="?primary-organization=${primary-organizationValue}"/>
</operation>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the client requested an Accept of the FHIR XML mime type 'application/fhir+xml'."/>
<direction value="request"/>
<headerField value="Accept"/>
<operator value="contains"/>
<value value="application/fhir+xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the client did not request a Content-Type. Warning only to allow for systems that automatically send Content-Type."/>
<direction value="request"/>
<headerField value="Content-Type"/>
<operator value="empty"/>
<warningOnly value="true"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned HTTP status is 200(OK)."/>
<direction value="response"/>
<responseCode value="200"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned HTTP Header Content-Type is present."/>
<direction value="response"/>
<headerField value="Content-Type"/>
<operator value="notEmpty"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned HTTP Header Content-Type contains the FHIR mime-type 'application/fhir+xml'."/>
<direction value="response"/>
<contentType value="xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned resource type is Bundle."/>
<direction value="response"/>
<resource value="Bundle"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned Bundle type is searchset."/>
<direction value="response"/>
<operator value="equals"/>
<path value="Bundle/type"/>
<value value="searchset"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle conforms to the base FHIR specification."/>
<direction value="response"/>
<validateProfileId value="bundle-profile"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned Bundle has more than 0 entries"/>
<direction value="response"/>
<expression value="Bundle.entry.count()"/>
<operator value="greaterThan"/>
<value value="0"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-rule">
<extension url="ruleId">
<valueId value="rule-validate-PDex-PlanNet"/>
</extension>
</extension>
<description value="Validate PDex OrganizationAffiliation within the search Bundle."/>
<direction value="response"/>
<warningOnly value="false"/>
</assert>
</action>
</test>
<test id="03-Search-OrganizationAffiliations-by-participating-organization">
<name value="SearchOrganizationAffiliations-by-participating-organization"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<action>
<operation>
<type>
<system value="http://terminology.hl7.org/CodeSystem/testscript-operation-codes"/>
<code value="search"/>
</type>
<resource value="OrganizationAffiliation"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<accept value="xml"/>
<destination value="1"/>
<encodeRequestUrl value="true"/>
<origin value="1"/>
<params value="?participating-organization=${participating-organizationValue}"/>
</operation>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the client requested an Accept of the FHIR XML mime type 'application/fhir+xml'."/>
<direction value="request"/>
<headerField value="Accept"/>
<operator value="contains"/>
<value value="application/fhir+xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the client did not request a Content-Type. Warning only to allow for systems that automatically send Content-Type."/>
<direction value="request"/>
<headerField value="Content-Type"/>
<operator value="empty"/>
<warningOnly value="true"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned HTTP status is 200(OK)."/>
<direction value="response"/>
<responseCode value="200"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned HTTP Header Content-Type is present."/>
<direction value="response"/>
<headerField value="Content-Type"/>
<operator value="notEmpty"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned HTTP Header Content-Type contains the FHIR mime-type 'application/fhir+xml'."/>
<direction value="response"/>
<contentType value="xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned resource type is Bundle."/>
<direction value="response"/>
<resource value="Bundle"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned Bundle type is searchset."/>
<direction value="response"/>
<operator value="equals"/>
<path value="Bundle/type"/>
<value value="searchset"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle conforms to the base FHIR specification."/>
<direction value="response"/>
<validateProfileId value="bundle-profile"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned Bundle has more than 0 entries"/>
<direction value="response"/>
<expression value="Bundle.entry.count()"/>
<operator value="greaterThan"/>
<value value="0"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-rule">
<extension url="ruleId">
<valueId value="rule-validate-PDex-PlanNet"/>
</extension>
</extension>
<description value="Validate PDex OrganizationAffiliation within the search Bundle."/>
<direction value="response"/>
<warningOnly value="false"/>
</assert>
</action>
</test>
<test id="04-Search-OrganizationAffiliations-by-location">
<name value="SearchOrganizationAffiliations-by-location"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<action>
<operation>
<type>
<system value="http://terminology.hl7.org/CodeSystem/testscript-operation-codes"/>
<code value="search"/>
</type>
<resource value="OrganizationAffiliation"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<accept value="xml"/>
<destination value="1"/>
<encodeRequestUrl value="true"/>
<origin value="1"/>
<params value="?location=${locationValue}"/>
</operation>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the client requested an Accept of the FHIR XML mime type 'application/fhir+xml'."/>
<direction value="request"/>
<headerField value="Accept"/>
<operator value="contains"/>
<value value="application/fhir+xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the client did not request a Content-Type. Warning only to allow for systems that automatically send Content-Type."/>
<direction value="request"/>
<headerField value="Content-Type"/>
<operator value="empty"/>
<warningOnly value="true"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned HTTP status is 200(OK)."/>
<direction value="response"/>
<responseCode value="200"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned HTTP Header Content-Type is present."/>
<direction value="response"/>
<headerField value="Content-Type"/>
<operator value="notEmpty"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned HTTP Header Content-Type contains the FHIR mime-type 'application/fhir+xml'."/>
<direction value="response"/>
<contentType value="xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned resource type is Bundle."/>
<direction value="response"/>
<resource value="Bundle"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned Bundle type is searchset."/>
<direction value="response"/>
<operator value="equals"/>
<path value="Bundle/type"/>
<value value="searchset"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle conforms to the base FHIR specification."/>
<direction value="response"/>
<validateProfileId value="bundle-profile"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned Bundle has more than 0 entries"/>
<direction value="response"/>
<expression value="Bundle.entry.count()"/>
<operator value="greaterThan"/>
<value value="0"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-rule">
<extension url="ruleId">
<valueId value="rule-validate-PDex-PlanNet"/>
</extension>
</extension>
<description value="Validate PDex OrganizationAffiliation within the search Bundle."/>
<direction value="response"/>
<warningOnly value="false"/>
</assert>
</action>
</test>
<test id="05-Search-OrganizationAffiliations-by-service">
<name value="SearchOrganizationAffiliations-by-service"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<action>
<operation>
<type>
<system value="http://terminology.hl7.org/CodeSystem/testscript-operation-codes"/>
<code value="search"/>
</type>
<resource value="OrganizationAffiliation"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<accept value="xml"/>
<destination value="1"/>
<encodeRequestUrl value="true"/>
<origin value="1"/>
<params value="?service=${serviceValue}"/>
</operation>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the client requested an Accept of the FHIR XML mime type 'application/fhir+xml'."/>
<direction value="request"/>
<headerField value="Accept"/>
<operator value="contains"/>
<value value="application/fhir+xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the client did not request a Content-Type. Warning only to allow for systems that automatically send Content-Type."/>
<direction value="request"/>
<headerField value="Content-Type"/>
<operator value="empty"/>
<warningOnly value="true"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned HTTP status is 200(OK)."/>
<direction value="response"/>
<responseCode value="200"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned HTTP Header Content-Type is present."/>
<direction value="response"/>
<headerField value="Content-Type"/>
<operator value="notEmpty"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned HTTP Header Content-Type contains the FHIR mime-type 'application/fhir+xml'."/>
<direction value="response"/>
<contentType value="xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned resource type is Bundle."/>
<direction value="response"/>
<resource value="Bundle"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned Bundle type is searchset."/>
<direction value="response"/>
<operator value="equals"/>
<path value="Bundle/type"/>
<value value="searchset"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle conforms to the base FHIR specification."/>
<direction value="response"/>
<validateProfileId value="bundle-profile"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned Bundle has more than 0 entries"/>
<direction value="response"/>
<expression value="Bundle.entry.count()"/>
<operator value="greaterThan"/>
<value value="0"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-rule">
<extension url="ruleId">
<valueId value="rule-validate-PDex-PlanNet"/>
</extension>
</extension>
<description value="Validate PDex OrganizationAffiliation within the search Bundle."/>
<direction value="response"/>
<warningOnly value="false"/>
</assert>
</action>
</test>
<test id="06-Search-OrganizationAffiliations-by-network">
<name value="SearchOrganizationAffiliations-by-network"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<action>
<operation>
<type>
<system value="http://terminology.hl7.org/CodeSystem/testscript-operation-codes"/>
<code value="search"/>
</type>
<resource value="OrganizationAffiliation"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<accept value="xml"/>
<destination value="1"/>
<encodeRequestUrl value="true"/>
<origin value="1"/>
<params value="?network=${networkValue}"/>
</operation>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the client requested an Accept of the FHIR XML mime type 'application/fhir+xml'."/>
<direction value="request"/>
<headerField value="Accept"/>
<operator value="contains"/>
<value value="application/fhir+xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the client did not request a Content-Type. Warning only to allow for systems that automatically send Content-Type."/>
<direction value="request"/>
<headerField value="Content-Type"/>
<operator value="empty"/>
<warningOnly value="true"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned HTTP status is 200(OK)."/>
<direction value="response"/>
<responseCode value="200"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned HTTP Header Content-Type is present."/>
<direction value="response"/>
<headerField value="Content-Type"/>
<operator value="notEmpty"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned HTTP Header Content-Type contains the FHIR mime-type 'application/fhir+xml'."/>
<direction value="response"/>
<contentType value="xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned resource type is Bundle."/>
<direction value="response"/>
<resource value="Bundle"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned Bundle type is searchset."/>
<direction value="response"/>
<operator value="equals"/>
<path value="Bundle/type"/>
<value value="searchset"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle conforms to the base FHIR specification."/>
<direction value="response"/>
<validateProfileId value="bundle-profile"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned Bundle has more than 0 entries"/>
<direction value="response"/>
<expression value="Bundle.entry.count()"/>
<operator value="greaterThan"/>
<value value="0"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-rule">
<extension url="ruleId">
<valueId value="rule-validate-PDex-PlanNet"/>
</extension>
</extension>
<description value="Validate PDex OrganizationAffiliation within the search Bundle."/>
<direction value="response"/>
<warningOnly value="false"/>
</assert>
</action>
</test>
<test id="07-Search-OrganizationAffiliations-by-endpoint">
<name value="SearchOrganizationAffiliations-by-endpoint"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<action>
<operation>
<type>
<system value="http://terminology.hl7.org/CodeSystem/testscript-operation-codes"/>
<code value="search"/>
</type>
<resource value="OrganizationAffiliation"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<accept value="xml"/>
<destination value="1"/>
<encodeRequestUrl value="true"/>
<origin value="1"/>
<params value="?endpoint=${endpointValue}"/>
</operation>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the client requested an Accept of the FHIR XML mime type 'application/fhir+xml'."/>
<direction value="request"/>
<headerField value="Accept"/>
<operator value="contains"/>
<value value="application/fhir+xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the client did not request a Content-Type. Warning only to allow for systems that automatically send Content-Type."/>
<direction value="request"/>
<headerField value="Content-Type"/>
<operator value="empty"/>
<warningOnly value="true"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned HTTP status is 200(OK)."/>
<direction value="response"/>
<responseCode value="200"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned HTTP Header Content-Type is present."/>
<direction value="response"/>
<headerField value="Content-Type"/>
<operator value="notEmpty"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned HTTP Header Content-Type contains the FHIR mime-type 'application/fhir+xml'."/>
<direction value="response"/>
<contentType value="xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned resource type is Bundle."/>
<direction value="response"/>
<resource value="Bundle"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned Bundle type is searchset."/>
<direction value="response"/>
<operator value="equals"/>
<path value="Bundle/type"/>
<value value="searchset"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle conforms to the base FHIR specification."/>
<direction value="response"/>
<validateProfileId value="bundle-profile"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned Bundle has more than 0 entries"/>
<direction value="response"/>
<expression value="Bundle.entry.count()"/>
<operator value="greaterThan"/>
<value value="0"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-rule">
<extension url="ruleId">
<valueId value="rule-validate-PDex-PlanNet"/>
</extension>
</extension>
<description value="Validate PDex OrganizationAffiliation within the search Bundle."/>
<direction value="response"/>
<warningOnly value="false"/>
</assert>
</action>
</test>
<test id="08-Search-OrganizationAffiliations-by-role">
<name value="SearchOrganizationAffiliations-by-role"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<action>
<operation>
<type>
<system value="http://terminology.hl7.org/CodeSystem/testscript-operation-codes"/>
<code value="search"/>
</type>
<resource value="OrganizationAffiliation"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<accept value="xml"/>
<destination value="1"/>
<encodeRequestUrl value="true"/>
<origin value="1"/>
<params value="?role=${roleValue}"/>
</operation>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the client requested an Accept of the FHIR XML mime type 'application/fhir+xml'."/>
<direction value="request"/>
<headerField value="Accept"/>
<operator value="contains"/>
<value value="application/fhir+xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the client did not request a Content-Type. Warning only to allow for systems that automatically send Content-Type."/>
<direction value="request"/>
<headerField value="Content-Type"/>
<operator value="empty"/>
<warningOnly value="true"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned HTTP status is 200(OK)."/>
<direction value="response"/>
<responseCode value="200"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned HTTP Header Content-Type is present."/>
<direction value="response"/>
<headerField value="Content-Type"/>
<operator value="notEmpty"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned HTTP Header Content-Type contains the FHIR mime-type 'application/fhir+xml'."/>
<direction value="response"/>
<contentType value="xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned resource type is Bundle."/>
<direction value="response"/>
<resource value="Bundle"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned Bundle type is searchset."/>
<direction value="response"/>
<operator value="equals"/>
<path value="Bundle/type"/>
<value value="searchset"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle conforms to the base FHIR specification."/>
<direction value="response"/>
<validateProfileId value="bundle-profile"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned Bundle has more than 0 entries"/>
<direction value="response"/>
<expression value="Bundle.entry.count()"/>
<operator value="greaterThan"/>
<value value="0"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-rule">
<extension url="ruleId">
<valueId value="rule-validate-PDex-PlanNet"/>
</extension>
</extension>
<description value="Validate PDex OrganizationAffiliation within the search Bundle."/>
<direction value="response"/>
<warningOnly value="false"/>
</assert>
</action>
</test>
<test id="09-Search-OrganizationAffiliations-by-specialty">
<name value="SearchOrganizationAffiliations-by-specialty"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<action>
<operation>
<type>
<system value="http://terminology.hl7.org/CodeSystem/testscript-operation-codes"/>
<code value="search"/>
</type>
<resource value="OrganizationAffiliation"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<accept value="xml"/>
<destination value="1"/>
<encodeRequestUrl value="true"/>
<origin value="1"/>
<params value="?specialty=${specialtyValue}"/>
</operation>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the client requested an Accept of the FHIR XML mime type 'application/fhir+xml'."/>
<direction value="request"/>
<headerField value="Accept"/>
<operator value="contains"/>
<value value="application/fhir+xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the client did not request a Content-Type. Warning only to allow for systems that automatically send Content-Type."/>
<direction value="request"/>
<headerField value="Content-Type"/>
<operator value="empty"/>
<warningOnly value="true"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned HTTP status is 200(OK)."/>
<direction value="response"/>
<responseCode value="200"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned HTTP Header Content-Type is present."/>
<direction value="response"/>
<headerField value="Content-Type"/>
<operator value="notEmpty"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned HTTP Header Content-Type contains the FHIR mime-type 'application/fhir+xml'."/>
<direction value="response"/>
<contentType value="xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned resource type is Bundle."/>
<direction value="response"/>
<resource value="Bundle"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned Bundle type is searchset."/>
<direction value="response"/>
<operator value="equals"/>
<path value="Bundle/type"/>
<value value="searchset"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle conforms to the base FHIR specification."/>
<direction value="response"/>
<validateProfileId value="bundle-profile"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned Bundle has more than 0 entries"/>
<direction value="response"/>
<expression value="Bundle.entry.count()"/>
<operator value="greaterThan"/>
<value value="0"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-rule">
<extension url="ruleId">
<valueId value="rule-validate-PDex-PlanNet"/>
</extension>
</extension>
<description value="Validate PDex OrganizationAffiliation within the search Bundle."/>
<direction value="response"/>
<warningOnly value="false"/>
</assert>
</action>
</test>
<test id="10-Search-OrganizationAffiliations-by-_id">
<name value="Search-OrganizationAffiliations-by-_id"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<action>
<operation>
<type>
<system value="http://terminology.hl7.org/CodeSystem/testscript-operation-codes"/>
<code value="search"/>
</type>
<resource value="OrganizationAffiliation"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<accept value="xml"/>
<destination value="1"/>
<encodeRequestUrl value="true"/>
<origin value="1"/>
<params value="?_id=${resourceId}"/>
</operation>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the client requested an Accept of the FHIR XML mime type 'application/fhir+xml'."/>
<direction value="request"/>
<headerField value="Accept"/>
<operator value="contains"/>
<value value="application/fhir+xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the client did not request a Content-Type. Warning only to allow for systems that automatically send Content-Type."/>
<direction value="request"/>
<headerField value="Content-Type"/>
<operator value="empty"/>
<warningOnly value="true"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned HTTP status is 200(OK)."/>
<direction value="response"/>
<responseCode value="200"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned HTTP Header Content-Type is present."/>
<direction value="response"/>
<headerField value="Content-Type"/>
<operator value="notEmpty"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned HTTP Header Content-Type contains the FHIR mime-type 'application/fhir+xml'."/>
<direction value="response"/>
<contentType value="xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned resource type is Bundle."/>
<direction value="response"/>
<resource value="Bundle"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned Bundle type is searchset."/>
<direction value="response"/>
<operator value="equals"/>
<path value="Bundle/type"/>
<value value="searchset"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle conforms to the base FHIR specification."/>
<direction value="response"/>
<validateProfileId value="bundle-profile"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle has more than 0 entries"/>
<direction value="response"/>
<expression value="Bundle.entry.count()"/>
<operator value="greaterThan"/>
<value value="0"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-rule">
<extension url="ruleId">
<valueId value="rule-validate-PDex-PlanNet"/>
</extension>
</extension>
<description value="Validate PDex OrganizationAffiliation within the search Bundle."/>
<direction value="response"/>
<warningOnly value="false"/>
</assert>
</action>
</test>
<test id="11-Search-OrganizationAffiliations-by-_lastUpdated">
<name value="Search-OrganizationAffiliations-by-_lastUpdated"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<action>
<operation>
<type>
<system value="http://terminology.hl7.org/CodeSystem/testscript-operation-codes"/>
<code value="search"/>
</type>
<resource value="OrganizationAffiliation"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<accept value="xml"/>
<destination value="1"/>
<encodeRequestUrl value="true"/>
<origin value="1"/>
<params value="?_lastUpdated=${lastUpdatedValue}"/>
</operation>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the client requested an Accept of the FHIR XML mime type 'application/fhir+xml'."/>
<direction value="request"/>
<headerField value="Accept"/>
<operator value="contains"/>
<value value="application/fhir+xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the client did not request a Content-Type. Warning only to allow for systems that automatically send Content-Type."/>
<direction value="request"/>
<headerField value="Content-Type"/>
<operator value="empty"/>
<warningOnly value="true"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned HTTP status is 200(OK)."/>
<direction value="response"/>
<responseCode value="200"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned HTTP Header Content-Type is present."/>
<direction value="response"/>
<headerField value="Content-Type"/>
<operator value="notEmpty"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned HTTP Header Content-Type contains the FHIR mime-type 'application/fhir+xml'."/>
<direction value="response"/>
<contentType value="xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned resource type is Bundle."/>
<direction value="response"/>
<resource value="Bundle"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned Bundle type is searchset."/>
<direction value="response"/>
<operator value="equals"/>
<path value="Bundle/type"/>
<value value="searchset"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle conforms to the base FHIR specification."/>
<direction value="response"/>
<validateProfileId value="bundle-profile"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle has more than 0 entries"/>
<direction value="response"/>
<expression value="Bundle.entry.count()"/>
<operator value="greaterThan"/>
<value value="0"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-rule">
<extension url="ruleId">
<valueId value="rule-validate-PDex-PlanNet"/>
</extension>
</extension>
<description value="Validate PDex OrganizationAffiliation within the search Bundle."/>
<direction value="response"/>
<warningOnly value="false"/>
</assert>
</action>
</test>
<test id="12-Search-OrganizationAffiliations-include-primary-organization">
<name value="SearchOrganizationAffiliations-include-primary-organization"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<action>
<operation>
<type>
<system value="http://terminology.hl7.org/CodeSystem/testscript-operation-codes"/>
<code value="search"/>
</type>
<resource value="OrganizationAffiliation"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<accept value="xml"/>
<destination value="1"/>
<encodeRequestUrl value="true"/>
<origin value="1"/>
<params value="?_include=OrganizationAffiliation:primary-organization&_count=100"/>
</operation>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the client requested an Accept of the FHIR XML mime type 'application/fhir+xml'."/>
<direction value="request"/>
<headerField value="Accept"/>
<operator value="contains"/>
<value value="application/fhir+xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the client did not request a Content-Type. Warning only to allow for systems that automatically send Content-Type."/>
<direction value="request"/>
<headerField value="Content-Type"/>
<operator value="empty"/>
<warningOnly value="true"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned HTTP status is 200(OK)."/>
<direction value="response"/>
<responseCode value="200"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned HTTP Header Content-Type is present."/>
<direction value="response"/>
<headerField value="Content-Type"/>
<operator value="notEmpty"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned HTTP Header Content-Type contains the FHIR mime-type 'application/fhir+xml'."/>
<direction value="response"/>
<contentType value="xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned resource type is Bundle."/>
<direction value="response"/>
<resource value="Bundle"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle type is searchset."/>
<direction value="response"/>
<operator value="equals"/>
<path value="Bundle/type"/>
<value value="searchset"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle conforms to the base FHIR specification."/>
<direction value="response"/>
<validateProfileId value="bundle-profile"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned Bundle has more than 0 entries"/>
<direction value="response"/>
<expression value="Bundle.entry.count()"/>
<operator value="greaterThan"/>
<value value="0"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle has at least one OrganizationAffiliation resource"/>
<direction value="response"/>
<expression value="Bundle.entry.select(resource as OrganizationAffiliation).exists()"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned Bundle has at least one Organization resource"/>
<direction value="response"/>
<expression value="Bundle.entry.select(resource as Organization).where((type.coding.code contains 'ntwk').not()).exists()"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-rule">
<extension url="ruleId">
<valueId value="rule-validate-PDex-PlanNet"/>
</extension>
</extension>
<description value="Validate PDex OrganizationAffiliation within the search Bundle."/>
<direction value="response"/>
<warningOnly value="false"/>
</assert>
</action>
</test>
<test id="13-Search-OrganizationAffiliations-include-participating-organization">
<name value="SearchOrganizationAffiliations-include-participating-organization"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<action>
<operation>
<type>
<system value="http://terminology.hl7.org/CodeSystem/testscript-operation-codes"/>
<code value="search"/>
</type>
<resource value="OrganizationAffiliation"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<accept value="xml"/>
<destination value="1"/>
<encodeRequestUrl value="true"/>
<origin value="1"/>
<params value="?_include=OrganizationAffiliation:participating-organization&_count=100"/>
</operation>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the client requested an Accept of the FHIR XML mime type 'application/fhir+xml'."/>
<direction value="request"/>
<headerField value="Accept"/>
<operator value="contains"/>
<value value="application/fhir+xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the client did not request a Content-Type. Warning only to allow for systems that automatically send Content-Type."/>
<direction value="request"/>
<headerField value="Content-Type"/>
<operator value="empty"/>
<warningOnly value="true"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned HTTP status is 200(OK)."/>
<direction value="response"/>
<responseCode value="200"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned HTTP Header Content-Type is present."/>
<direction value="response"/>
<headerField value="Content-Type"/>
<operator value="notEmpty"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned HTTP Header Content-Type contains the FHIR mime-type 'application/fhir+xml'."/>
<direction value="response"/>
<contentType value="xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned resource type is Bundle."/>
<direction value="response"/>
<resource value="Bundle"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle type is searchset."/>
<direction value="response"/>
<operator value="equals"/>
<path value="Bundle/type"/>
<value value="searchset"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle conforms to the base FHIR specification."/>
<direction value="response"/>
<validateProfileId value="bundle-profile"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned Bundle has more than 0 entries"/>
<direction value="response"/>
<expression value="Bundle.entry.count()"/>
<operator value="greaterThan"/>
<value value="0"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle has at least one OrganizationAffiliation resource"/>
<direction value="response"/>
<expression value="Bundle.entry.select(resource as OrganizationAffiliation).exists()"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned Bundle has at least one Organization resource"/>
<direction value="response"/>
<expression value="Bundle.entry.select(resource as Organization).where((type.coding.code contains 'ntwk').not()).exists()"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-rule">
<extension url="ruleId">
<valueId value="rule-validate-PDex-PlanNet"/>
</extension>
</extension>
<description value="Validate PDex OrganizationAffiliation within the search Bundle."/>
<direction value="response"/>
<warningOnly value="false"/>
</assert>
</action>
</test>
<test id="14-Search-OrganizationAffiliations-include-location">
<name value="SearchOrganizationAffiliations-include-location"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<action>
<operation>
<type>
<system value="http://terminology.hl7.org/CodeSystem/testscript-operation-codes"/>
<code value="search"/>
</type>
<resource value="OrganizationAffiliation"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<accept value="xml"/>
<destination value="1"/>
<encodeRequestUrl value="true"/>
<origin value="1"/>
<params value="?_include=OrganizationAffiliation:location&_count=100"/>
</operation>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the client requested an Accept of the FHIR XML mime type 'application/fhir+xml'."/>
<direction value="request"/>
<headerField value="Accept"/>
<operator value="contains"/>
<value value="application/fhir+xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the client did not request a Content-Type. Warning only to allow for systems that automatically send Content-Type."/>
<direction value="request"/>
<headerField value="Content-Type"/>
<operator value="empty"/>
<warningOnly value="true"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned HTTP status is 200(OK)."/>
<direction value="response"/>
<responseCode value="200"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned HTTP Header Content-Type is present."/>
<direction value="response"/>
<headerField value="Content-Type"/>
<operator value="notEmpty"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned HTTP Header Content-Type contains the FHIR mime-type 'application/fhir+xml'."/>
<direction value="response"/>
<contentType value="xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned resource type is Bundle."/>
<direction value="response"/>
<resource value="Bundle"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle type is searchset."/>
<direction value="response"/>
<operator value="equals"/>
<path value="Bundle/type"/>
<value value="searchset"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle conforms to the base FHIR specification."/>
<direction value="response"/>
<validateProfileId value="bundle-profile"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned Bundle has more than 0 entries"/>
<direction value="response"/>
<expression value="Bundle.entry.count()"/>
<operator value="greaterThan"/>
<value value="0"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle has at least one OrganizationAffiliation resource"/>
<direction value="response"/>
<expression value="Bundle.entry.select(resource as OrganizationAffiliation).exists()"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle has at least one Location resource"/>
<direction value="response"/>
<expression value="Bundle.entry.select(resource as Location).exists()"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-rule">
<extension url="ruleId">
<valueId value="rule-validate-PDex-PlanNet"/>
</extension>
</extension>
<description value="Validate PDex OrganizationAffiliation within the search Bundle."/>
<direction value="response"/>
<warningOnly value="false"/>
</assert>
</action>
</test>
<test id="15-Search-OrganizationAffiliations-include-service">
<name value="SearchOrganizationAffiliations-include-service"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<action>
<operation>
<type>
<system value="http://terminology.hl7.org/CodeSystem/testscript-operation-codes"/>
<code value="search"/>
</type>
<resource value="OrganizationAffiliation"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<accept value="xml"/>
<destination value="1"/>
<encodeRequestUrl value="true"/>
<origin value="1"/>
<params value="?_include=OrganizationAffiliation:service&_count=100"/>
</operation>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the client requested an Accept of the FHIR XML mime type 'application/fhir+xml'."/>
<direction value="request"/>
<headerField value="Accept"/>
<operator value="contains"/>
<value value="application/fhir+xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the client did not request a Content-Type. Warning only to allow for systems that automatically send Content-Type."/>
<direction value="request"/>
<headerField value="Content-Type"/>
<operator value="empty"/>
<warningOnly value="true"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned HTTP status is 200(OK)."/>
<direction value="response"/>
<responseCode value="200"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned HTTP Header Content-Type is present."/>
<direction value="response"/>
<headerField value="Content-Type"/>
<operator value="notEmpty"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned HTTP Header Content-Type contains the FHIR mime-type 'application/fhir+xml'."/>
<direction value="response"/>
<contentType value="xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned resource type is Bundle."/>
<direction value="response"/>
<resource value="Bundle"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle type is searchset."/>
<direction value="response"/>
<operator value="equals"/>
<path value="Bundle/type"/>
<value value="searchset"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle conforms to the base FHIR specification."/>
<direction value="response"/>
<validateProfileId value="bundle-profile"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned Bundle has more than 0 entries"/>
<direction value="response"/>
<expression value="Bundle.entry.count()"/>
<operator value="greaterThan"/>
<value value="0"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle has at least one OrganizationAffiliation resource"/>
<direction value="response"/>
<expression value="Bundle.entry.select(resource as OrganizationAffiliation).exists()"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle has at least one HealthcareService resource"/>
<direction value="response"/>
<expression value="Bundle.entry.select(resource as HealthcareService).exists()"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-rule">
<extension url="ruleId">
<valueId value="rule-validate-PDex-PlanNet"/>
</extension>
</extension>
<description value="Validate PDex OrganizationAffiliation within the search Bundle."/>
<direction value="response"/>
<warningOnly value="false"/>
</assert>
</action>
</test>
<test id="16-Search-OrganizationAffiliations-include-endpoint">
<name value="SearchOrganizationAffiliations-include-endpoint"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<action>
<operation>
<type>
<system value="http://terminology.hl7.org/CodeSystem/testscript-operation-codes"/>
<code value="search"/>
</type>
<resource value="OrganizationAffiliation"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<accept value="xml"/>
<destination value="1"/>
<encodeRequestUrl value="true"/>
<origin value="1"/>
<params value="?_include=OrganizationAffiliation:endpoint&_count=100"/>
</operation>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the client requested an Accept of the FHIR XML mime type 'application/fhir+xml'."/>
<direction value="request"/>
<headerField value="Accept"/>
<operator value="contains"/>
<value value="application/fhir+xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the client did not request a Content-Type. Warning only to allow for systems that automatically send Content-Type."/>
<direction value="request"/>
<headerField value="Content-Type"/>
<operator value="empty"/>
<warningOnly value="true"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned HTTP status is 200(OK)."/>
<direction value="response"/>
<responseCode value="200"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned HTTP Header Content-Type is present."/>
<direction value="response"/>
<headerField value="Content-Type"/>
<operator value="notEmpty"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned HTTP Header Content-Type contains the FHIR mime-type 'application/fhir+xml'."/>
<direction value="response"/>
<contentType value="xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned resource type is Bundle."/>
<direction value="response"/>
<resource value="Bundle"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle type is searchset."/>
<direction value="response"/>
<operator value="equals"/>
<path value="Bundle/type"/>
<value value="searchset"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle conforms to the base FHIR specification."/>
<direction value="response"/>
<validateProfileId value="bundle-profile"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned Bundle has more than 0 entries"/>
<direction value="response"/>
<expression value="Bundle.entry.count()"/>
<operator value="greaterThan"/>
<value value="0"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle has at least one OrganizationAffiliation resource"/>
<direction value="response"/>
<expression value="Bundle.entry.select(resource as OrganizationAffiliation).exists()"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle has at least one Endpoint resource"/>
<direction value="response"/>
<expression value="Bundle.entry.select(resource as Endpoint).exists()"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-rule">
<extension url="ruleId">
<valueId value="rule-validate-PDex-PlanNet"/>
</extension>
</extension>
<description value="Validate PDex OrganizationAffiliation within the search Bundle."/>
<direction value="response"/>
<warningOnly value="false"/>
</assert>
</action>
</test>
<test id="17-Search-OrganizationAffiliations-include-network">
<name value="SearchOrganizationAffiliations-include-network"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<action>
<operation>
<type>
<system value="http://terminology.hl7.org/CodeSystem/testscript-operation-codes"/>
<code value="search"/>
</type>
<resource value="OrganizationAffiliation"/>
<description value="Search for OrganizationAffiliations conforming to the PlanNet-OrganizationAffiliation profile."/>
<accept value="xml"/>
<destination value="1"/>
<encodeRequestUrl value="true"/>
<origin value="1"/>
<params value="?_include=OrganizationAffiliation:network&_count=100"/>
</operation>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the client requested an Accept of the FHIR XML mime type 'application/fhir+xml'."/>
<direction value="request"/>
<headerField value="Accept"/>
<operator value="contains"/>
<value value="application/fhir+xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the client did not request a Content-Type. Warning only to allow for systems that automatically send Content-Type."/>
<direction value="request"/>
<headerField value="Content-Type"/>
<operator value="empty"/>
<warningOnly value="true"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned HTTP status is 200(OK)."/>
<direction value="response"/>
<responseCode value="200"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned HTTP Header Content-Type is present."/>
<direction value="response"/>
<headerField value="Content-Type"/>
<operator value="notEmpty"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned HTTP Header Content-Type contains the FHIR mime-type 'application/fhir+xml'."/>
<direction value="response"/>
<contentType value="xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned resource type is Bundle."/>
<direction value="response"/>
<resource value="Bundle"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle type is searchset."/>
<direction value="response"/>
<operator value="equals"/>
<path value="Bundle/type"/>
<value value="searchset"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle conforms to the base FHIR specification."/>
<direction value="response"/>
<validateProfileId value="bundle-profile"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle has more than 0 entries"/>
<direction value="response"/>
<expression value="Bundle.entry.count()"/>
<operator value="greaterThan"/>
<value value="0"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned Bundle has at least one OrganizationAffiliation resource"/>
<direction value="response"/>
<expression value="Bundle.entry.select(resource as OrganizationAffiliation).exists()"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned Bundle has at least one Network resource"/>
<direction value="response"/>
<expression value="Bundle.entry.select(resource as Organization).where((type.coding.code contains 'ntwk')).exists()"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-rule">
<extension url="ruleId">
<valueId value="rule-validate-PDex-PlanNet"/>
</extension>
</extension>
<description value="Validate PDex OrganizationAffiliation within the search Bundle."/>
<direction value="response"/>
<warningOnly value="false"/>
</assert>
</action>
</test>
<test id="18-Read-OrganizationAffiliations">
<name value="ReadOrganizationAffiliations"/>
<description value="Read an OrganizationAffiliation conforming to the PlanNet-OrganizationAffiliation profile."/>
<action>
<operation>
<type>
<system value="http://terminology.hl7.org/CodeSystem/testscript-operation-codes"/>
<code value="read"/>
</type>
<resource value="OrganizationAffiliation"/>
<description value="Read an OrganizationAffiliation conforming to the PlanNet-OrganizationAffiliation profile."/>
<accept value="xml"/>
<destination value="1"/>
<encodeRequestUrl value="true"/>
<origin value="1"/>
<params value="/${resourceId}"/>
</operation>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the client requested an Accept of the FHIR XML mime type 'application/fhir+xml'."/>
<direction value="request"/>
<headerField value="Accept"/>
<operator value="contains"/>
<value value="application/fhir+xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the client did not request a Content-Type. Warning only to allow for systems that automatically send Content-Type."/>
<direction value="request"/>
<headerField value="Content-Type"/>
<operator value="empty"/>
<warningOnly value="true"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned HTTP status is 200(OK)."/>
<direction value="response"/>
<responseCode value="200"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned HTTP Header Content-Type is present."/>
<direction value="response"/>
<headerField value="Content-Type"/>
<operator value="notEmpty"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Confirm that the returned HTTP Header Content-Type contains the FHIR mime-type 'application/fhir+xml'."/>
<direction value="response"/>
<contentType value="xml"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned resource type is OrganizationAffiliation."/>
<direction value="response"/>
<resource value="OrganizationAffiliation"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Validate PDex OrganizationAffiliation within the response."/>
<direction value="response"/>
<validateProfileId value="PDex-PlanNet-OrganizationAffiliation-profile"/>
<warningOnly value="false"/>
</assert>
</action>
</test>
<test id="19-Vread-OrganizationAffiliations">
<name value="VreadOrganizationAffiliations"/>
<description value="Vread an OrganizationAffiliation conforming to the PlanNet-OrganizationAffiliation profile. Test systems SHOULD support VRead."/>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-rule">
<extension url="ruleId">
<valueId value="rule-GetVariable-FhirPath"/>
</extension>
<extension url="param">
<extension url="name">
<valueString value="fhirPath"/>
</extension>
<extension url="value">
<valueString value="Bundle.entry.resource.meta.versionId"/>
</extension>
</extension>
<extension url="param">
<extension url="name">
<valueString value="outputName"/>
</extension>
<extension url="value">
<valueString value="versionId"/>
</extension>
</extension>
<extension url="output">
<extension url="name">
<valueString value="versionId"/>
</extension>
</extension>
</extension>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Rules to gather the versionId if assigned, else use the default value '1'."/>
<sourceId value="searchResponse"/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<assert>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-rule">
<extension url="ruleId">
<valueId value="rule-ReplaceNullVariable"/>
</extension>
<extension url="param">
<extension url="name">
<valueString value="trueValue"/>
</extension>
<extension url="value">
<valueString value="${versionId}"/>
</extension>
</extension>
<extension url="param">
<extension url="name">
<valueString value="defaultValue"/>
</extension>
<extension url="value">
<valueString value="1"/>
</extension>
</extension>
<extension url="param">
<extension url="name">
<valueString value="outputName"/>
</extension>
<extension url="value">
<valueString value="versionId-resolved"/>
</extension>
</extension>
<extension url="output">
<extension url="name">
<valueString value="versionId-resolved"/>
</extension>
</extension>
</extension>
<extension url="http://touchstone.aegis.net/touchstone/fhir/testing/StructureDefinition/testscript-assert-stopTestOnFail">
<valueBoolean value="false"/>
</extension>
<description value="Rules to gather the versionId if assigned, else use the default value '1'."/>
<warningOnly value="false"/>
</assert>
</action>
<action>
<operation>
<type>
<system value="http://terminology.hl7.org/CodeSystem/testscript-operation-codes"/>
<code value="vread"/>
</type>
<resource value="OrganizationAffiliation"/>
<description value="Vread an OrganizationAffiliation conforming to the PlanNet-OrganizationAffiliation profile."/>
<accept value="xml"/>
<destination value="1"/>
<encodeRequestUrl value="true"/>
<origin value="1"/>
<params value="/${resourceId}/_history/${versionId-resolved}"/>
</operation>
</action>
<action>
<assert>
<description value="Confirm that the client requested an Accept of the FHIR XML mime type 'application/fhir+xml'."/>
<direction value="request"/>
<headerField value="Accept"/>
<operator value="contains"/>
<value value="application/fhir+xml"/>
<warningOnly value="true"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the client did not request a Content-Type. Warning only to allow for systems that automatically send Content-Type."/>
<direction value="request"/>
<headerField value="Content-Type"/>
<operator value="empty"/>
<warningOnly value="true"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned HTTP status is 200(OK)."/>
<direction value="response"/>
<responseCode value="200"/>
<warningOnly value="true"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned HTTP Header Content-Type is present."/>
<direction value="response"/>
<headerField value="Content-Type"/>
<operator value="notEmpty"/>
<warningOnly value="true"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned HTTP Header Content-Type contains the FHIR mime-type 'application/fhir+xml'."/>
<direction value="response"/>
<contentType value="xml"/>
<warningOnly value="true"/>
</assert>
</action>
<action>
<assert>
<description value="Confirm that the returned resource type is OrganizationAffiliation."/>
<direction value="response"/>
<resource value="OrganizationAffiliation"/>
<warningOnly value="true"/>
</assert>
</action>
<action>
<assert>
<description value="Validate PDex OrganizationAffiliation within the response. Warning only because vread is a SHOULD."/>
<direction value="response"/>
<validateProfileId value="PDex-PlanNet-OrganizationAffiliation-profile"/>
<warningOnly value="true"/>
</assert>
</action>
</test>
</TestScript>