Generated Narrative: TestScript fastconsentfileconsentxml
StructureDefinition Work Group: cbcc
url: TestScript FAST Consent fileConsent XML
version: 0.1.0
name: FASTConsentFileConsentXML
title: FAST Consent fileConsent XML
status: Active
date: 2025-05-22
publisher: HL7 International / Community Based Collaborative Care
contact: HL7 International / Community Based Collaborative Care: http://www.hl7.org/Special/committees/cbcc
description:
Test a FAST Consent Management Server implementation of the $fileConsent operation using XML Format
\njurisdiction: United States of America
copyright:
(c) HL7 International / Community Based Collaborative Care 2025
\n- | Index | Profile |
* | 1 | Test script profile origin type FHIR-Client: FHIR Client |
- | Index | Profile |
* | 1 | Test script profile destination type FHIR-Server: FHIR Server |
fixture
id
fileconsent-parametersautocreate: false
autodelete: false
resource:
./Parameters-fileconsent.xml
profile:
- | Name | Expression | SourceId |
* | createConsentIdentifier | Parameters.parameter.where(name = 'consent').resource.identifier[0].value | fileconsent-parameters |
test
id
FASTConsentFileConsentXMLname: FASTConsentFileConsentXML
description: Test a FAST Consent Management Server implementation of the $fileConsent operation using XML Format against the destination server and assert successful response.
action
Operations
- Type Resource Description Accept ContentType Destination EncodeRequestUrl Origin Params SourceId * Test script operation code fileConsent: fileConsent Consent Send a Consent $fileConsent operation xml xml 1 true 1 /$fileConsent fileconsent-parameters action
Asserts
- Extension Description Direction Resource WarningOnly * Confirm that the sent request payload is a Parameters resource. request Parameters true action
Asserts
- Extension Description Direction ValidateProfileId WarningOnly * Confirm that the sent Parameters conforms to the FAST Consent profile. request fileConsentParametersProfile false action
Asserts
- Extension Description Direction ResponseCode WarningOnly * Confirm that the returned response code is 200 OK. response 200 false action
Asserts
- Extension Description Direction Resource WarningOnly * Confirm that the returned response payload is an OperationOutcome resource. response OperationOutcome true action
Asserts
- Extension Description Direction ValidateProfileId WarningOnly * Confirm that the returned OperationOutcome conforms to the base FHIR specification. response OperationOutcomeProfile true
test
id
FASTConsentSearchXMLname: FASTConsentSearchXML
description: Test a FAST Consent Management Server to confirm successful creation of Consent from previous $fileConsent operation.
action
Operations
- Type Resource Description Accept ContentType Destination EncodeRequestUrl Origin Params * Test script operation code search: Search Consent Search for Consent from $fileConsent operation xml xml 1 true 1 ?identifier=${createConsentIdentifier} action
Asserts
- Extension Description Direction ResponseCode WarningOnly * Confirm that the returned response code is 200 OK. response 200 false action
Asserts
- Extension Description Direction Resource WarningOnly * Confirm that the returned response payload is a Bundle resource. response Bundle true action
Asserts
- Extension Description Direction Path Value WarningOnly * Confirm that the returned response payload is a searchset Bundle resource. response Bundle/type searchset true action
Asserts
- Extension Description Direction Expression Value WarningOnly * Confirm that the returned searchset Bundle contains 1 match. response Bundle.entry.resource.count() 1 true action
Asserts
- Extension Description Direction Expression WarningOnly * Confirm that the returned searchset Bundle contains a Consent resource. response Bundle.entry.resource.as(Consent).exists() true action
Asserts
- Extension Description Direction Expression Value WarningOnly * Confirm that the returned searchset Bundle contains the created Consent resource. response Bundle.entry.resource.as(Consent).identifier[0].value ${createConsentIdentifier} true