Test Script

Name/FHIR1-8-0-Advanced/Patient/04-update/fhir-api-stu3-patient-update-02-notok
DescriptionFHIR API STU3 Advanced Operation Tests - Patient update test suite against a single server using invalid resource instances where all the expected results are not successful. The expected outcome of each test execution is a failed update operation. The destination server must also support the create, search and delete operations in order to determine the generated resource id and then clean up any created resources. Testing for 422 (Unprocessable Entity) is out of scope and not included. Assertions test all required and optional response HTTP Headers and validate the returned payload.
Version1Latest1
Content
<?xml version="1.0" encoding="UTF-8"?>

<TestScript xmlns="http://hl7.org/fhir">  
    <id value="fhir-api-stu3-patient-update-02-notok"/>  
    <text> 
        <status value="generated"/>  
        <div xmlns="http://www.w3.org/1999/xhtml">  
            <p>FHIR API STU3 - Patient Update Not OK Resource Suite</p> 
        </div> 
    </text>  
    <url value="http://wildfhir.aegis.net/fhir/TestScript/fhir-api-stu3-patient-update-02-notok"/>  
    <name value="FHIR API STU3 - Patient Update Not OK Resource Suite"/>  
    <status value="draft"/>  
    <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>  
    <date value="2016-12-13"/>  
    <description value="FHIR API STU3 Advanced Operation Tests - Patient update test suite against a single server using invalid resource instances where all the expected results are not successful. The expected outcome of each test execution is a failed update operation. The destination server must also support the create, search and delete operations in order to determine the generated resource id and then clean up any created resources. Testing for 422 (Unprocessable Entity) is out of scope and not included. Assertions test all required and optional response HTTP Headers and validate the returned payload."/>  
    <copyright value="© AEGIS.net, Inc. 2015+"/>  
    <metadata> 
        <capability> 
            <required value="true"/>  
            <description value="Update, Create, Search and Delete Operation"/>  
            <link value="http://hl7.org/fhir/2017Jan/http.html#create"/>  
            <link value="http://hl7.org/fhir/2017Jan/http.html#search"/>  
            <link value="http://hl7.org/fhir/2017Jan/http.html#update"/>  
            <link value="http://hl7.org/fhir/2017Jan/http.html#delete"/>  
            <capabilities> 
                <reference value="../_reference/capabilities/PatientUpdateNotOK.xml"/> 
            </capabilities> 
        </capability> 
    </metadata>  
    <fixture id="resource-update-notok-01-json-setup"> 
        <resource> 
            <reference value="../_reference/resources/Patient-update-notok-01-json-setup.json"/> 
        </resource> 
    </fixture>  
    <fixture id="resource-update-notok-01-json-noid"> 
        <resource> 
            <reference value="../_reference/resources/Patient-update-notok-01-json-noid.json"/> 
        </resource> 
    </fixture>  
    <fixture id="resource-update-notok-01-json-invalid-syntax"> 
        <resource> 
            <reference value="../_reference/resources/Patient-update-notok-01-json-invalid-syntax.json"/> 
        </resource> 
    </fixture>  
    <fixture id="resource-update-notok-01-json-bad-profile"> 
        <resource> 
            <reference value="../_reference/resources/Patient-update-notok-01-json-bad-profile.json"/> 
        </resource> 
    </fixture>  
    <fixture id="resource-update-notok-02-xml-setup"> 
        <resource> 
            <reference value="../_reference/resources/Patient-update-notok-02-xml-setup.xml"/> 
        </resource> 
    </fixture>  
    <fixture id="resource-update-notok-02-xml-noid"> 
        <resource> 
            <reference value="../_reference/resources/Patient-update-notok-02-xml-noid.xml"/> 
        </resource> 
    </fixture>  
    <fixture id="resource-update-notok-02-xml-invalid-syntax"> 
        <resource> 
            <reference value="../_reference/resources/Patient-update-notok-02-xml-invalid-syntax.xml"/> 
        </resource> 
    </fixture>  
    <fixture id="resource-update-notok-02-xml-bad-profile"> 
        <resource> 
            <reference value="../_reference/resources/Patient-update-notok-02-xml-bad-profile.xml"/> 
        </resource> 
    </fixture>  
    <profile id="resource-profile"> 
        <reference value="http://hl7.org/fhir/StructureDefinition/Patient"/> 
    </profile>  
    <variable> 
        <name value="update-notok-01-json-setup-id"/>  
        <path value="Patient/id"/>  
        <sourceId value="update-notok-01-json-setup-search-response"/> 
    </variable>  
    <variable> 
        <name value="search-update-notok-01-json-setup-identifier"/>  
        <path value="Patient/identifier/value"/>  
        <sourceId value="resource-update-notok-01-json-setup"/> 
    </variable>  
    <variable> 
        <name value="update-notok-02-xml-setup-id"/>  
        <path value="Patient/id"/>  
        <sourceId value="update-notok-02-xml-setup-search-response"/> 
    </variable>  
    <variable> 
        <name value="search-update-notok-02-xml-setup-identifier"/>  
        <path value="Patient/identifier/value"/>  
        <sourceId value="resource-update-notok-02-xml-setup"/> 
    </variable>  
    <setup> 
        <action> 
            <operation> 
                <type> 
                    <system value="http://hl7.org/fhir/testscript-operation-codes"/>  
                    <code value="delete"/> 
                </type>  
                <resource value="Patient"/>  
                <description value="System-generated search and delete operations from conditional delete to insure the Patient 1 does not exist on the server."/>  
                <accept value="json"/>  
                <contentType value="none"/>  
                <params value="?identifier=${search-update-notok-01-json-setup-identifier}"/> 
            </operation> 
        </action>  
        <action> 
            <operation> 
                <type> 
                    <system value="http://hl7.org/fhir/testscript-operation-codes"/>  
                    <code value="delete"/> 
                </type>  
                <resource value="Patient"/>  
                <description value="System-generated search and delete operations from conditional delete to insure the Patient 2 does not exist on the server."/>  
                <accept value="xml"/>  
                <contentType value="none"/>  
                <params value="?identifier=${search-update-notok-02-xml-setup-identifier}"/> 
            </operation> 
        </action>  
        <action> 
            <operation> 
                <type> 
                    <system value="http://hl7.org/fhir/testscript-operation-codes"/>  
                    <code value="create"/> 
                </type>  
                <resource value="Patient"/>  
                <description value="Create the Patient resource for test 01 in JSON format on the destination server."/>  
                <accept value="json"/>  
                <contentType value="json"/>  
                <sourceId value="resource-update-notok-01-json-setup"/> 
            </operation> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP status is 201(Created)."/>  
                <direction value="response"/>  
                <responseCode value="201"/> 
            </assert> 
        </action>  
        <action> 
            <operation> 
                <type> 
                    <system value="http://hl7.org/fhir/testscript-operation-codes"/>  
                    <code value="search"/> 
                </type>  
                <resource value="Patient"/>  
                <description value="Search for the test 01 created Patient by the unique identifier."/>  
                <accept value="json"/>  
                <contentType value="json"/>  
                <params value="?identifier=${search-update-notok-01-json-setup-identifier}"/>  
                <responseId value="update-notok-01-json-setup-search-response"/> 
            </operation> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP status is 200(OK)."/>  
                <direction value="response"/>  
                <responseCode value="200"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header Content-Type contains the FHIR mime-type 'application/fhir+json'."/>  
                <contentType value="json"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned resource type is Bundle."/>  
                <resource value="Bundle"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that returned bundle first entry contains the created version of the Patient."/>  
                <minimumId value="resource-update-notok-01-json-setup"/> 
            </assert> 
        </action>  
        <action> 
            <operation> 
                <type> 
                    <system value="http://hl7.org/fhir/testscript-operation-codes"/>  
                    <code value="create"/> 
                </type>  
                <resource value="Patient"/>  
                <description value="Create the Patient resource for test 02 in XML format on the destination server."/>  
                <accept value="json"/>  
                <contentType value="json"/>  
                <sourceId value="resource-update-notok-02-xml-setup"/> 
            </operation> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP status is 201(Created)."/>  
                <direction value="response"/>  
                <responseCode value="201"/> 
            </assert> 
        </action>  
        <action> 
            <operation> 
                <type> 
                    <system value="http://hl7.org/fhir/testscript-operation-codes"/>  
                    <code value="search"/> 
                </type>  
                <resource value="Patient"/>  
                <description value="Search for the test 02 created Patient by the unique identifier."/>  
                <accept value="xml"/>  
                <contentType value="xml"/>  
                <params value="?identifier=${search-update-notok-02-xml-setup-identifier}"/>  
                <responseId value="update-notok-02-xml-setup-search-response"/> 
            </operation> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP status is 200(OK)."/>  
                <direction value="response"/>  
                <responseCode value="200"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header Content-Type contains the FHIR mime-type 'application/fhir+xml'."/>  
                <contentType value="xml"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned resource type is Bundle."/>  
                <resource value="Bundle"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that returned bundle first entry contains the created version of the Patient."/>  
                <minimumId value="resource-update-notok-02-xml-setup"/> 
            </assert> 
        </action> 
    </setup>  
    <test id="01-UpdateNotOKJSONNoId"> 
        <name value="UpdateNotOKJSONNoId"/>  
        <description value="Test the update operation with JSON content where the request resource content does not contain a resource id. The expected HTTP response is 400 (Bad Request) and optional content of an OperationOutcome resource in JSON format."/>  
        <action> 
            <operation> 
                <type> 
                    <system value="http://hl7.org/fhir/testscript-operation-codes"/>  
                    <code value="update"/> 
                </type>  
                <resource value="Patient"/>  
                <description value="Patient update operation with JSON content where the request resource content does not contain a resource id. The response asserts for all the optional HTTP Headers will be warning only."/>  
                <accept value="json"/>  
                <contentType value="json"/>  
                <params value="/${update-notok-01-json-setup-id}"/>  
                <sourceId value="resource-update-notok-01-json-noid"/> 
            </operation> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP status is 400(Bad Request)."/>  
                <direction value="response"/>  
                <responseCode value="400"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header Content-Type is present. Warning only as a response content is optional but servers are encouraged to return this."/>  
                <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+json'. Warning only as a response content is optional but servers are encouraged to return this."/>  
                <direction value="response"/>  
                <headerField value="Content-Type"/>  
                <operator value="contains"/>  
                <value value="application/fhir+json"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header Content-Type contains 'charset=utf-8'. Warning only as a response content is optional but servers are encouraged to return this."/>  
                <direction value="response"/>  
                <headerField value="Content-Type"/>  
                <operator value="contains"/>  
                <value value="charset=utf-8"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header ETag is not present. Warning only to allow subsequent asserts to execute."/>  
                <direction value="response"/>  
                <headerField value="ETag"/>  
                <operator value="empty"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header Last-Modified is not present. Warning only to allow subsequent asserts to execute."/>  
                <direction value="response"/>  
                <headerField value="Last-Modified"/>  
                <operator value="empty"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header Location is not present. Warning only to allow subsequent asserts to execute."/>  
                <direction value="response"/>  
                <headerField value="Location"/>  
                <operator value="empty"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned resource type is OperationOutcome. Warning only as this is optional but servers are encouraged to return an OperationOutcome on failure."/>  
                <resource value="OperationOutcome"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action> 
    </test>  
    <test id="02-UpdateNotOKXMLNoId"> 
        <name value="UpdateNotOKXMLNoId"/>  
        <description value="Test the update operation with XML content where the request resource content does not contain a resource id. The expected HTTP response is 400 (Bad Request) and optional content of an OperationOutcome resource in XML format."/>  
        <action> 
            <operation> 
                <type> 
                    <system value="http://hl7.org/fhir/testscript-operation-codes"/>  
                    <code value="update"/> 
                </type>  
                <resource value="Patient"/>  
                <description value="Patient create operation with XML content where the request resource content does not contain a resource id. The response asserts for all the optional HTTP Headers will be warning only."/>  
                <accept value="xml"/>  
                <contentType value="xml"/>  
                <params value="/${update-notok-02-xml-setup-id}"/>  
                <sourceId value="resource-update-notok-02-xml-noid"/> 
            </operation> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP status is 400(Bad Request)."/>  
                <direction value="response"/>  
                <responseCode value="400"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header Content-Type is present. Warning only as a response content is optional but servers are encouraged to return this."/>  
                <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'. Warning only as a response content is optional but servers are encouraged to return this."/>  
                <direction value="response"/>  
                <headerField value="Content-Type"/>  
                <operator value="contains"/>  
                <value value="application/fhir+xml"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header Content-Type contains 'charset=utf-8'. Warning only as a response content is optional but servers are encouraged to return this."/>  
                <direction value="response"/>  
                <headerField value="Content-Type"/>  
                <operator value="contains"/>  
                <value value="charset=utf-8"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header ETag is not present. Warning only to allow subsequent asserts to execute."/>  
                <direction value="response"/>  
                <headerField value="ETag"/>  
                <operator value="empty"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header Last-Modified is not present. Warning only to allow subsequent asserts to execute."/>  
                <direction value="response"/>  
                <headerField value="Last-Modified"/>  
                <operator value="empty"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header Location is not present. Warning only to allow subsequent asserts to execute."/>  
                <direction value="response"/>  
                <headerField value="Location"/>  
                <operator value="empty"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned resource type is OperationOutcome. Warning only as this is optional but servers are encouraged to return an OperationOutcome on failure."/>  
                <resource value="OperationOutcome"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action> 
    </test>  
    <test id="03-UpdateNotOKJSONInvalidSyntax"> 
        <name value="UpdateNotOKJSONInvalidSyntax"/>  
        <description value="Test the update operation with JSON content where the request resource content is invalid based on an invalid birthDate date value. The expected HTTP response is 400 (Bad Request) and optional content of an OperationOutcome resource in JSON format."/>  
        <action> 
            <operation> 
                <type> 
                    <system value="http://hl7.org/fhir/testscript-operation-codes"/>  
                    <code value="update"/> 
                </type>  
                <resource value="Patient"/>  
                <description value="Patient update operation with JSON content where the request resource content is invalid based on invalid birthDate date value. The response asserts for all the optional HTTP Headers will be warning only."/>  
                <accept value="json"/>  
                <contentType value="json"/>  
                <params value="/${update-notok-01-json-setup-id}"/>  
                <sourceId value="resource-update-notok-01-json-invalid-syntax"/> 
            </operation> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP status is 400(Bad Request)."/>  
                <direction value="response"/>  
                <responseCode value="400"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header Content-Type is present. Warning only as a response content is optional but servers are encouraged to return this."/>  
                <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+json'. Warning only as a response content is optional but servers are encouraged to return this."/>  
                <direction value="response"/>  
                <headerField value="Content-Type"/>  
                <operator value="contains"/>  
                <value value="application/fhir+json"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header Content-Type contains 'charset=utf-8'. Warning only as a response content is optional but servers are encouraged to return this."/>  
                <direction value="response"/>  
                <headerField value="Content-Type"/>  
                <operator value="contains"/>  
                <value value="charset=utf-8"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header ETag is not present. Warning only to allow subsequent asserts to execute."/>  
                <direction value="response"/>  
                <headerField value="ETag"/>  
                <operator value="empty"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header Last-Modified is not present. Warning only to allow subsequent asserts to execute."/>  
                <direction value="response"/>  
                <headerField value="Last-Modified"/>  
                <operator value="empty"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header Location is not present. Warning only to allow subsequent asserts to execute."/>  
                <direction value="response"/>  
                <headerField value="Location"/>  
                <operator value="empty"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned resource type is OperationOutcome. Warning only as this is optional but servers are encouraged to return an OperationOutcome on failure."/>  
                <resource value="OperationOutcome"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action> 
    </test>  
    <test id="04-UpdateNotOKXMLInvalidSyntax"> 
        <name value="UpdateNotOKXMLInvalidSyntax"/>  
        <description value="Test the update operation with XML content where the request resource content is invalid based on invalid birthDate date value. The expected HTTP response is 400 (Bad Request) and optional content of an OperationOutcome resource in XML format."/>  
        <action> 
            <operation> 
                <type> 
                    <system value="http://hl7.org/fhir/testscript-operation-codes"/>  
                    <code value="update"/> 
                </type>  
                <resource value="Patient"/>  
                <description value="Patient update operation with XML content where the request resource content is invalid based on invalid birthDate date value. The response asserts for all the optional HTTP Headers will be warning only."/>  
                <accept value="xml"/>  
                <contentType value="xml"/>  
                <params value="/${update-notok-02-xml-setup-id}"/>  
                <sourceId value="resource-update-notok-02-xml-invalid-syntax"/> 
            </operation> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP status is 400(Bad Request)."/>  
                <direction value="response"/>  
                <responseCode value="400"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header Content-Type is present. Warning only as a response content is optional but servers are encouraged to return this."/>  
                <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'. Warning only as a response content is optional but servers are encouraged to return this."/>  
                <direction value="response"/>  
                <headerField value="Content-Type"/>  
                <operator value="contains"/>  
                <value value="application/fhir+xml"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header Content-Type contains 'charset=utf-8'. Warning only as a response content is optional but servers are encouraged to return this."/>  
                <direction value="response"/>  
                <headerField value="Content-Type"/>  
                <operator value="contains"/>  
                <value value="charset=utf-8"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header ETag is not present. Warning only to allow subsequent asserts to execute."/>  
                <direction value="response"/>  
                <headerField value="ETag"/>  
                <operator value="empty"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header Last-Modified is not present. Warning only to allow subsequent asserts to execute."/>  
                <direction value="response"/>  
                <headerField value="Last-Modified"/>  
                <operator value="empty"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header Location is not present. Warning only to allow subsequent asserts to execute."/>  
                <direction value="response"/>  
                <headerField value="Location"/>  
                <operator value="empty"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned resource type is OperationOutcome. Warning only as this is optional but servers are encouraged to return an OperationOutcome on failure."/>  
                <resource value="OperationOutcome"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action> 
    </test>  
    <test id="05-UpdateNotOKJSONBadProfile"> 
        <name value="UpdateNotOKJSONBadProfile"/>  
        <description value="Test the update operation with JSON content where the request resource content is invalid based on non-conformance to the base FHIR resource profile. The expected HTTP response is 400 (Bad Request) and optional content of an OperationOutcome resource in JSON format."/>  
        <action> 
            <operation> 
                <type> 
                    <system value="http://hl7.org/fhir/testscript-operation-codes"/>  
                    <code value="update"/> 
                </type>  
                <resource value="Patient"/>  
                <description value="Patient update operation with JSON content where the request resource content is invalid based on non-conformance to the base FHIR resource profile. The response asserts for all the optional HTTP Headers will be warning only."/>  
                <accept value="json"/>  
                <contentType value="json"/>  
                <params value="/${update-notok-01-json-setup-id}"/>  
                <sourceId value="resource-update-notok-01-json-bad-profile"/> 
            </operation> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP status is 400(Bad Request)."/>  
                <direction value="response"/>  
                <responseCode value="400"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header Content-Type is present. Warning only as a response content is optional but servers are encouraged to return this."/>  
                <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+json'. Warning only as a response content is optional but servers are encouraged to return this."/>  
                <direction value="response"/>  
                <headerField value="Content-Type"/>  
                <operator value="contains"/>  
                <value value="application/fhir+json"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header Content-Type contains 'charset=utf-8'. Warning only as a response content is optional but servers are encouraged to return this."/>  
                <direction value="response"/>  
                <headerField value="Content-Type"/>  
                <operator value="contains"/>  
                <value value="charset=utf-8"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header ETag is not present. Warning only to allow subsequent asserts to execute."/>  
                <direction value="response"/>  
                <headerField value="ETag"/>  
                <operator value="empty"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header Last-Modified is not present. Warning only to allow subsequent asserts to execute."/>  
                <direction value="response"/>  
                <headerField value="Last-Modified"/>  
                <operator value="empty"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header Location is not present. Warning only to allow subsequent asserts to execute."/>  
                <direction value="response"/>  
                <headerField value="Location"/>  
                <operator value="empty"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned resource type is OperationOutcome. Warning only as this is optional but servers are encouraged to return an OperationOutcome on failure."/>  
                <resource value="OperationOutcome"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action> 
    </test>  
    <test id="06-UpdateNotOKXMLBadProfile"> 
        <name value="UpdateNotOKXMLBadProfile"/>  
        <description value="Test the update operation with XML content where the request resource content is invalid based on non-conformance to the base FHIR resource profile. The expected HTTP response is 400 (Bad Request) and optional content of an OperationOutcome resource in XML format."/>  
        <action> 
            <operation> 
                <type> 
                    <system value="http://hl7.org/fhir/testscript-operation-codes"/>  
                    <code value="update"/> 
                </type>  
                <resource value="Patient"/>  
                <description value="Patient update operation with XML content where the request resource content is invalid based on non-conformance to the base FHIR resource profile. The response asserts for all the optional HTTP Headers will be warning only."/>  
                <accept value="xml"/>  
                <contentType value="xml"/>  
                <params value="/${update-notok-02-xml-setup-id}"/>  
                <sourceId value="resource-update-notok-02-xml-bad-profile"/> 
            </operation> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP status is 400(Bad Request)."/>  
                <direction value="response"/>  
                <responseCode value="400"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header Content-Type is present. Warning only as a response content is optional but servers are encouraged to return this."/>  
                <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'. Warning only as a response content is optional but servers are encouraged to return this."/>  
                <direction value="response"/>  
                <headerField value="Content-Type"/>  
                <operator value="contains"/>  
                <value value="application/fhir+xml"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header Content-Type contains 'charset=utf-8'. Warning only as a response content is optional but servers are encouraged to return this."/>  
                <direction value="response"/>  
                <headerField value="Content-Type"/>  
                <operator value="contains"/>  
                <value value="charset=utf-8"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header ETag is not present. Warning only to allow subsequent asserts to execute."/>  
                <direction value="response"/>  
                <headerField value="ETag"/>  
                <operator value="empty"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header Last-Modified is not present. Warning only to allow subsequent asserts to execute."/>  
                <direction value="response"/>  
                <headerField value="Last-Modified"/>  
                <operator value="empty"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned HTTP Header Location is not present. Warning only to allow subsequent asserts to execute."/>  
                <direction value="response"/>  
                <headerField value="Location"/>  
                <operator value="empty"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action>  
        <action> 
            <assert> 
                <description value="Confirm that the returned resource type is OperationOutcome. Warning only as this is optional but servers are encouraged to return an OperationOutcome on failure."/>  
                <resource value="OperationOutcome"/>  
                <warningOnly value="true"/> 
            </assert> 
        </action> 
    </test>  
    <teardown> 
        <action> 
            <operation> 
                <type> 
                    <code value="delete"/> 
                </type>  
                <resource value="Patient"/>  
                <params value="/${update-notok-01-json-setup-id}"/> 
            </operation> 
        </action>  
        <action> 
            <operation> 
                <type> 
                    <code value="delete"/> 
                </type>  
                <resource value="Patient"/>  
                <params value="/${update-notok-02-xml-setup-id}"/> 
            </operation> 
        </action> 
    </teardown> 
</TestScript>