TestScript
type: StructureDefinition
node role: treeRoot
id:
  v: TestScript
meta:
  last updated:
    v: 2021-01-05T10:01:24.148+11:00
language:
  v: en
text:
  status:
    v: extensions
  div:
    v: Generated Narrative: StructureDefinition TestScript Last updated: 2021-01-05 10:01:24+1100 Name Flags Card. Type Description & Constraints<img src="[binary]" alt="doco" style="background-color: inherit"/> TestScript C 1..1 CanonicalResource Describes a set of tests Elements defined in Ancestors:id, meta, implicitRules, language, <a href="http://hl7.org/fhir/R5/domainresource.html" title="A human-readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it "clinically safe" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.">text, contained, <a href="http://hl7.org/fhir/R5/domainresource.html" title="May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.">extension, <a href="http://hl7.org/fhir/R5/domainresource.html" title="May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier exten…
extension:
  url:
    v: http://hl7.org/fhir/StructureDefinition/structuredefinition-category
    l: structuredefinition-category
  value: String
    v: Specialized.Quality Reporting & Testing
extension:
  url:
    v: http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status
    l: structuredefinition-standards-status
  value: Code
    v: trial-use
extension:
  url:
    v: http://hl7.org/fhir/StructureDefinition/structuredefinition-fmm
    l: structuredefinition-fmm
  value: Integer
    v: 4
extension:
  url:
    v: http://hl7.org/fhir/StructureDefinition/structuredefinition-security-category
    l: structuredefinition-security-category
  value: Code
    v: anonymous
extension:
  url:
    v: http://hl7.org/fhir/StructureDefinition/structuredefinition-wg
    l: structuredefinition-wg
  value: Code
    v: fhir
extension:
  url:
    v: http://hl7.org/fhir/tools/StructureDefinition/entered-in-error-status
    l: entered-in-error-status
  value: String
    v: .status = retired
extension:
  url:
    v: http://hl7.org/fhir/tools/StructureDefinition/additional-resource
    l: additional-resource
  value: Boolean
    v: true
extension:
  url:
    v: http://hl7.org/fhir/StructureDefinition/structuredefinition-interface
    l: structuredefinition-interface
  value: Boolean
    v: true
url:
  v: http://hl7.org/fhir/StructureDefinition/TestScript
  l: TestScript
identifier:
  system:
    v: urn:ietf:rfc:3986
    l: 3986
  value:
    v: urn:oid:2.16.840.1.113883.4.642.5.1082
version:
  v: 0.1.0-SNAPSHOT
name:
  v: TestScript
title:
  v: Test Script
status:
  v: draft
date:
  v: 2021-01-05T10:01:24+11:00
publisher:
  v: HL7 International / FHIR Infrastructure
contact:
  telecom:
    system:
      v: url
    value:
      v: http://www.hl7.org/Special/committees/fiwg
description:
  v: A structured set of tests against a FHIR server or client implementation to determine compliance against the FHIR specification.
jurisdiction:
  coding:
    system:
      v: http://unstats.un.org/unsd/methods/m49/m49.htm
      l: m49.htm
    code:
      v: 001
fhir version:
  v: 6.0.0-ballot3
mapping:
  identity:
    v: rim
  uri:
    v: http://hl7.org/v3
    l: v3
  name:
    v: RIM Mapping
mapping:
  identity:
    v: w5
  uri:
    v: http://hl7.org/fhir/fivews
    l: fivews
  name:
    v: FiveWs Pattern Mapping
mapping:
  identity:
    v: workflow
  uri:
    v: http://hl7.org/fhir/workflow
    l: workflow
  name:
    v: Workflow Pattern
mapping:
  identity:
    v: objimpl
  uri:
    v: http://hl7.org/fhir/object-implementation
    l: object-implementation
  name:
    v: Object Implementation Information
kind:
  v: resource
abstract:
  v: false
type:
  v: TestScript
  l: TestScript
base definition:
  v: http://hl7.org/fhir/StructureDefinition/CanonicalResource
  l: CanonicalResource
derivation:
  v: specialization
snapshot:
  extension:
    url:
      v: http://hl7.org/fhir/tools/StructureDefinition/snapshot-base-version
      l: snapshot-base-version
    value: String
      v: 6.0.0-ballot3
  element:
    id:
      v: TestScript
    path:
      v: TestScript
    short:
      v: Describes a set of tests
    definition:
      v: A structured set of tests against a FHIR server or client implementation to determine compliance against the FHIR specification.
    min:
      v: 1
    max:
      v: 1
    base:
      path:
        v: CanonicalResource
      min:
        v: 1
      max:
        v: 1
    constraint:
      key:
        v: cnl-0
      severity:
        v: warning
      human:
        v: Name should be usable as an identifier for the module by machine processing applications such as code generation
      expression:
        v: name.exists() implies name.matches('^[A-Z]([A-Za-z0-9_]){1,254}$')
      source:
        v: http://hl7.org/fhir/StructureDefinition/CanonicalResource
        l: CanonicalResource
    constraint:
      key:
        v: dom-2
      severity:
        v: error
      human:
        v: If the resource is contained in another resource, it SHALL NOT contain nested Resources
      expression:
        v: contained.contained.empty()
      source:
        v: http://hl7.org/fhir/StructureDefinition/DomainResource
        l: DomainResource
    constraint:
      key:
        v: dom-3
      severity:
        v: error
      human:
        v: If the resource is contained in another resource, it SHALL be referred to from elsewhere in the resource or SHALL refer to the containing resource
      expression:
        v: contained.where((('#'+id.trace('id') in %resource.descendants().select(reference | as(uri))) or descendants().where(reference='#' | as(uri)='#').exists()).not()).trace('unmatched', id).empty()

key:
  v: dom-4
severity:
  v: error
human:
  v: If a resource is contained in another resource, it SHALL NOT have a meta.versionId or a meta.lastUpdated
expression:
  v: contained.meta.versionId.empty() and contained.meta.lastUpdated.empty()
source:
  v: http://hl7.org/fhir/StructureDefinition/DomainResource
  l: DomainResource

key:
  v: dom-5
severity:
  v: error
human:
  v: If a resource is contained in another resource, it SHALL NOT have a security label
expression:
  v: contained.meta.security.empty()
source:
  v: http://hl7.org/fhir/StructureDefinition/DomainResource
  l: DomainResource

extension:
  url:
    v: http://hl7.org/fhir/StructureDefinition/elementdefinition-bestpractice
    l: elementdefinition-bestpractice
  value: Boolean
    v: true
extension:
  url:
    v: http://hl7.org/fhir/StructureDefinition/elementdefinition-bestpractice-explanation
    l: elementdefinition-bestpractice-explanation
  value: Markdown
    v: When a resource has no narrative, only systems that fully understand the data can display the resource to a human safely. Including a human readable representation in the resource makes for a much more robust eco-system and cheaper handling of resources by intermediary systems. Some ecosystems restrict distribution of resources to only those systems that do fully understand the resources, and as a consequence implementers may believe that the narrative is superfluous. However experience shows that such eco-systems often open up to new participants over time.
key:
  v: dom-6
severity:
  v: warning
human:
  v: A resource should have narrative for robust management
expression:
  v: text.`div`.exists()
source:
  v: http://hl7.org/fhir/StructureDefinition/DomainResource
  l: DomainResource

v: false

v: false

v: false

identity:
  v: workflow
map:
  v: Definition

identity:
  v: rim
map:
  v: n/a,Entity,Role,or Act

identity:
  v: w5
map:
  v: conformance.misc,conformance.behavior

id:
  v: TestScript.id
path:
  v: TestScript.id
short:
  v: Logical id of this artifact
definition:
  v: The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes.
comment:
  v: Within the context of the FHIR RESTful interactions, the resource has an id except for cases like the create and conditional update. Otherwise, the use of the resouce id depends on the given use case.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Resource.id
  min:
    v: 0
  max:
    v: 1
type:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
      l: structuredefinition-fhir-type
    value: Url
      v: id
      l: id
  code:
    v: http://hl7.org/fhirpath/System.String
    l: System.String
must support:
  v: false
is modifier:
  v: false
is summary:
  v: true

id:
  v: TestScript.meta
path:
  v: TestScript.meta
short:
  v: Metadata about the resource
definition:
  v: The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Resource.meta
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: Meta
    l: Meta
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
must support:
  v: false
is modifier:
  v: false
is summary:
  v: true

id:
  v: TestScript.implicitRules
path:
  v: TestScript.implicitRules
short:
  v: A set of rules under which this content was created
definition:
  v: A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc.
comment:
  v: Asserting this rule set restricts the content to be only understood by a limited set of trading partners. This inherently limits the usefulness of the data in the long term. However, the existing health eco-system is highly fractured, and not yet ready to define, collect, and exchange data in a generally computable sense. Wherever possible, implementers and/or specification writers should avoid using this element. Often, when used, the URL is a reference to an implementation guide that defines these special rules as part of its narrative along with other profiles, value sets, etc.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Resource.implicitRules
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: uri
    l: uri
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
must support:
  v: false
is modifier:
  v: true
is modifier reason:
  v: This element is labeled as a modifier because the implicit rules may provide additional knowledge about the resource that modifies its meaning or interpretation
is summary:
  v: true

id:
  v: TestScript.language
path:
  v: TestScript.language
short:
  v: Language of the resource content
definition:
  v: The base language in which the resource is written.
comment:
  v: Language is provided to support indexing and accessibility (typically, services such as text to speech use the language tag). The html language tag in the narrative applies to the narrative. The language tag on the resource may be used to specify the language of other presentations generated from the data in the resource. Not all the content has to be in the base language. The Resource.language should not be assumed to apply to the narrative automatically. If a language is specified, it should it also be specified on the div element in the html (see rules in HTML5 for information about the relationship between xml:lang and the html lang attribute).
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Resource.language
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: code
    l: code
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
must support:
  v: false
is modifier:
  v: false
is summary:
  v: false
binding:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
      l: elementdefinition-bindingName
    value: String
      v: Language
  strength:
    v: required
  description:
    v: IETF language tag for a human language
  value set:
    v: http://hl7.org/fhir/ValueSet/all-languages|6.0.0-ballot3
    l: http://hl7.org/fhir/ValueSet/all-languages
  additional:
    purpose:
      v: starter
    value set:
      v: http://hl7.org/fhir/ValueSet/languages|6.0.0-ballot3
      l: http://hl7.org/fhir/ValueSet/languages

id:
  v: TestScript.text
path:
  v: TestScript.text
short:
  v: Text summary of the resource, for human interpretation
definition:
  v: A human-readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it "clinically safe" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety.
comment:
  v: Contained resources do not have a narrative. Resources that are not contained SHOULD have a narrative. In some cases, a resource may only have text with little or no additional discrete data (as long as all minOccurs=1 elements are satisfied). This may be necessary for data from legacy systems where information is captured as a "text blob" or where text is additionally entered raw or narrated and encoded information is added later.
alias:
  v: narrative
alias:
  v: html
alias:
  v: xhtml
alias:
  v: display
min:
  v: 0
max:
  v: 1
base:
  path:
    v: DomainResource.text
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: Narrative
    l: Narrative
condition:
  v: dom-6
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
must support:
  v: false
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: Act.text?

id:
  v: TestScript.contained
path:
  v: TestScript.contained
short:
  v: Contained, inline Resources
definition:
  v: These resources do not have an independent existence apart from the resource that contains them - they cannot be identified independently, nor can they have their own independent transaction scope. This is allowed to be a Parameters resource if and only if it is referenced by a resource that provides context/meaning.
comment:
  v: This should never be done when the content can be identified properly, as once identification is lost, it is extremely difficult (and context dependent) to restore it again. Contained resources may have profiles and tags in their meta elements, but SHALL NOT have security labels. Contained resources may be a resource type defined in the FHIR specification, or an [additional resource](http://build.fhir.org/resource.html#additional).
alias:
  v: inline resources
alias:
  v: anonymous resources
alias:
  v: contained resources
min:
  v: 0
max:
  v: *
base:
  path:
    v: DomainResource.contained
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Resource
    l: Resource
condition:
  v: dom-2
condition:
  v: dom-4
condition:
  v: dom-3
condition:
  v: dom-5
must support:
  v: false
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: N/A

id:
  v: TestScript.extension
path:
  v: TestScript.extension
short:
  v: Additional content defined by implementations
definition:
  v: May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
alias:
  v: extensions
alias:
  v: user content
min:
  v: 0
max:
  v: *
base:
  path:
    v: DomainResource.extension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
must support:
  v: false
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: N/A

id:
  v: TestScript.modifierExtension
path:
  v: TestScript.modifierExtension
short:
  v: Extensions that cannot be ignored
definition:
  v: May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions. Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
requirements:
  v: Modifier extensions allow for extensions that *cannot* be safely ignored to be clearly distinguished from the vast majority of extensions which can be safely ignored. This promotes interoperability by eliminating the need for implementers to prohibit the presence of extensions. For further information, see the [definition of modifier extensions](http://build.fhir.org/extensibility.html#modifierExtension).
alias:
  v: extensions
alias:
  v: user content
min:
  v: 0
max:
  v: *
base:
  path:
    v: DomainResource.modifierExtension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
must support:
  v: false
is modifier:
  v: true
is modifier reason:
  v: Modifier extensions are expected to modify the meaning or interpretation of the resource that contains them
is summary:
  v: true
mapping:
  identity:
    v: rim
  map:
    v: N/A

id:
  v: TestScript.url
path:
  v: TestScript.url
short:
  v: Canonical identifier for this test script, represented as a URI (globally unique)
definition:
  v: An absolute URI that is used to identify this test script when it is referenced in a specification, model, design or an instance; also called its canonical identifier. This SHOULD be globally unique and SHOULD be a literal address at which an authoritative instance of this test script is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the test script is stored on different servers.
comment:
  v: Can be a urn:uuid: or a urn:oid: but real http: addresses are preferred. Multiple instances may share the same URL if they have a distinct version. The determination of when to create a new version of a resource (same url, new version) vs. defining a new artifact is up to the author. Considerations for making this decision are found in [Technical and Business Versions](resource.html#versions). In some cases, the resource can no longer be found at the stated url, but the url itself cannot change. Implementations can use the [meta.source](resource.html#meta) element to indicate where the current master source of the resource can be found.
requirements:
  v: Allows the test script to be referenced by a single globally unique identifier.
alias:
  v: url
alias:
  v: authoritative-url
alias:
  v: destination
alias:
  v: identity
min:
  v: 0
max:
  v: 1
base:
  path:
    v: CanonicalResource.url
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: uri
    l: uri
constraint:
  key:
    v: cnl-1
  severity:
    v: warning
  human:
    v: URL should not contain | or # - these characters make processing canonical references problematic
  expression:
    v: exists() implies matches('^[^|# ]+$')
  source:
    v: http://hl7.org/fhir/StructureDefinition/CanonicalResource
    l: CanonicalResource
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
must support:
  v: false
is modifier:
  v: false
is summary:
  v: true
mapping:
  identity:
    v: workflow
  map:
    v: Definition.url
mapping:
  identity:
    v: w5
  map:
    v: FiveWs.identifier

id:
  v: TestScript.identifier
path:
  v: TestScript.identifier
short:
  v: Additional identifier for the test script
definition:
  v: A formal identifier that is used to identify this test script when it is represented in other formats, or referenced in a specification, model, design or an instance.
requirements:
  v: Allows externally provided and/or usable business identifiers to be easily associated with the module.
min:
  v: 0
max:
  v: *
base:
  path:
    v: CanonicalResource.identifier
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Identifier
    l: Identifier
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
must support:
  v: false
is modifier:
  v: false
is summary:
  v: true
mapping:
  identity:
    v: workflow
  map:
    v: Definition.identifier
mapping:
  identity:
    v: w5
  map:
    v: FiveWs.identifier
mapping:
  identity:
    v: objimpl
  map:
    v: no-gen-base

id:
  v: TestScript.version
path:
  v: TestScript.version
short:
  v: Business version of the test script
definition:
  v: The identifier that is used to identify this version of the test script when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the test script author and is not expected to be globally unique. For example, it might be a timestamp (e.g. yyyymmdd) if a managed version is not available. There is also no expectation that versions can be placed in a lexicographical sequence.
comment:
  v: There may be different test script instances that have the same identifier but different versions. The version can be appended to the url in a reference to allow a reference to a particular business version of the test script with the format [url]|[version]. The version SHOULD NOT contain a '#' - see [Business Version](resource.html#bv-format).
min:
  v: 0
max:
  v: 1
base:
  path:
    v: CanonicalResource.version
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
must support:
  v: false
is modifier:
  v: false
is summary:
  v: true
mapping:
  identity:
    v: workflow
  map:
    v: Definition.version
mapping:
  identity:
    v: w5
  map:
    v: FiveWs.version

id:
  v: TestScript.versionAlgorithm[x]
path:
  v: TestScript.versionAlgorithm[x]
short:
  v: How to compare versions
definition:
  v: Indicates the mechanism used to compare versions to determine which is more current.
comment:
  v: If set as a string, this is a FHIRPath expression that has two additional context variables passed in - %version1 and %version2 and will return a negative number if version1 is newer, a positive number if version2 and a 0 if the version ordering can't be successfully be determined.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: CanonicalResource.versionAlgorithm[x]
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string
type:
  code:
    v: Coding
    l: Coding
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
must support:
  v: false
is modifier:
  v: false
is summary:
  v: true
binding:
  strength:
    v: extensible
  value set:
    v: http://hl7.org/fhir/ValueSet/version-algorithm
    l: version-algorithm

id:
  v: TestScript.name
path:
  v: TestScript.name
short:
  v: Name for this test script (computer friendly)
definition:
  v: A natural language name identifying the test script. This name should be usable as an identifier for the module by machine processing applications such as code generation.
comment:
  v: The name is not expected to be globally unique. The name should be a simple alphanumeric type name to ensure that it is machine-processing friendly.
requirements:
  v: Support code generation.
min:
  v: 1
max:
  v: 1
base:
  path:
    v: CanonicalResource.name
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string
condition:
  v: cnl-0
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
must support:
  v: false
is modifier:
  v: false
is summary:
  v: true
mapping:
  identity:
    v: workflow
  map:
    v: Definition.name

id:
  v: TestScript.title
extension:
  url:
    v: http://hl7.org/fhir/StructureDefinition/elementdefinition-translatable
    l: elementdefinition-translatable
  value: Boolean
    v: true
path:
  v: TestScript.title
short:
  v: Name for this test script (human friendly)
definition:
  v: A short, descriptive, user-friendly title for the test script.
comment:
  v: This name does not need to be machine-processing friendly and may contain punctuation, white-space, etc.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: CanonicalResource.title
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
must support:
  v: false
is modifier:
  v: false
is summary:
  v: true
mapping:
  identity:
    v: workflow
  map:
    v: Definition.title

id:
  v: TestScript.status
path:
  v: TestScript.status
short:
  v: draft | active | retired | unknown
definition:
  v: The status of this test script. Enables tracking the life-cycle of the content.
comment:
  v: Allows filtering of test scripts that are appropriate for use versus not. See guidance around (not) making local changes to elements [here](canonicalresource.html#localization).
requirements:
  v: Enables tracking the life-cycle of the content and filtering of {{title}}s that are appropriate for use versus not.
min:
  v: 1
max:
  v: 1
base:
  path:
    v: CanonicalResource.status
  min:
    v: 1
  max:
    v: 1
type:
  code:
    v: code
    l: code
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
must support:
  v: false
is modifier:
  v: true
is modifier reason:
  v: This is labeled as "Is Modifier" because applications should not use a retired {{title}} without due consideration
is summary:
  v: true
binding:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
      l: elementdefinition-bindingName
    value: String
      v: PublicationStatus
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-isCommonBinding
      l: elementdefinition-isCommonBinding
    value: Boolean
      v: true
  strength:
    v: required
  description:
    v: The lifecycle status of an artifact.
  value set:
    v: http://hl7.org/fhir/ValueSet/publication-status
    l: publication-status
mapping:
  identity:
    v: workflow
  map:
    v: Definition.status
mapping:
  identity:
    v: w5
  map:
    v: FiveWs.status

id:
  v: TestScript.experimental
path:
  v: TestScript.experimental
short:
  v: For testing only - never for real usage
definition:
  v: A Boolean value to indicate that this test script is authored for testing purposes (or education/evaluation/marketing) and no version of this resource will ever be intended for genuine usage.
comment:
  v: Allows filtering of test scripts that are appropriate for use versus not.. Experimental resources might include example instances in implementation guides, instances created solely for testing purposes, etc
requirements:
  v: Enables experimental content to be developed following the same lifecycle that would be used for a production-level test script.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: CanonicalResource.experimental
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: boolean
    l: boolean
meaning when missing:
  v: If absent, this resource is treated as though it is not experimental.
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
must support:
  v: false
is modifier:
  v: false
is summary:
  v: true
mapping:
  identity:
    v: workflow
  map:
    v: Definition.experimental
mapping:
  identity:
    v: w5
  map:
    v: FiveWs.class

id:
  v: TestScript.date
path:
  v: TestScript.date
short:
  v: Date last changed
definition:
  v: The date (and optionally time) when the test script was last significantly changed. The date must change when the business version changes and it must change if the status code changes. In addition, it should change when the substantive content of the test script changes.
comment:
  v: The date is often not tracked until the resource is published, but may be present on draft content. Note that this is not the same as the resource last-modified-date, since the resource may be a secondary representation of the test script. Additional specific dates may be added as extensions or be found by consulting Provenances associated with past versions of the resource. See guidance around (not) making local changes to elements [here](canonicalresource.html#localization).
alias:
  v: Revision Date
min:
  v: 0
max:
  v: 1
base:
  path:
    v: CanonicalResource.date
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: dateTime
    l: dateTime
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
must support:
  v: false
is modifier:
  v: false
is summary:
  v: true
mapping:
  identity:
    v: workflow
  map:
    v: Definition.date
mapping:
  identity:
    v: w5
  map:
    v: FiveWs.recorded

id:
  v: TestScript.publisher
extension:
  url:
    v: http://hl7.org/fhir/StructureDefinition/elementdefinition-translatable
    l: elementdefinition-translatable
  value: Boolean
    v: true
path:
  v: TestScript.publisher
short:
  v: Name of the publisher/steward (organization or individual)
definition:
  v: The name of the organization or individual responsible for the release and ongoing maintenance of the test script.
comment:
  v: Usually an organization but may be an individual. The publisher (or steward) of the test script is the organization or individual primarily responsible for the maintenance and upkeep of the test script. This is not necessarily the same individual or organization that developed and initially authored the content. The publisher is the primary point of contact for questions or issues with the test script. This item SHOULD be populated unless the information is available from context.
requirements:
  v: Helps establish the "authority/credibility" of the test script. May also allow for contact.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: CanonicalResource.publisher
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
must support:
  v: false
is modifier:
  v: false
is summary:
  v: true
mapping:
  identity:
    v: workflow
  map:
    v: Definition.publisher
mapping:
  identity:
    v: w5
  map:
    v: FiveWs.witness

id:
  v: TestScript.contact
path:
  v: TestScript.contact
short:
  v: Contact details for the publisher
definition:
  v: Contact details to assist a user in finding and communicating with the publisher.
comment:
  v: May be a web site, an email address, a telephone number, etc. See guidance around (not) making local changes to elements [here](canonicalresource.html#localization).
min:
  v: 0
max:
  v: *
base:
  path:
    v: CanonicalResource.contact
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: ContactDetail
    l: ContactDetail
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
must support:
  v: false
is modifier:
  v: false
is summary:
  v: true
mapping:
  identity:
    v: workflow
  map:
    v: Definition.contact

id:
  v: TestScript.description
extension:
  url:
    v: http://hl7.org/fhir/StructureDefinition/elementdefinition-translatable
    l: elementdefinition-translatable
  value: Boolean
    v: true
path:
  v: TestScript.description
short:
  v: Natural language description of the test script
definition:
  v: A free text natural language description of the test script from a consumer's perspective.
comment:
  v: This description can be used to capture details such as comments about misuse, instructions for clinical use and interpretation, literature references, examples from the paper world, etc. It is not a rendering of the test script as conveyed in the 'text' field of the resource itself. This item SHOULD be populated unless the information is available from context (e.g. the language of the test script is presumed to be the predominant language in the place the test script was created).
min:
  v: 0
max:
  v: 1
base:
  path:
    v: CanonicalResource.description
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: markdown
    l: markdown
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
must support:
  v: false
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: workflow
  map:
    v: Definition.description

id:
  v: TestScript.useContext
path:
  v: TestScript.useContext
short:
  v: The context that the content is intended to support
definition:
  v: The content was developed with a focus and intent of supporting the contexts that are listed. These contexts may be general categories (gender, age, ...) or may be references to specific programs (insurance plans, studies, ...) and may be used to assist with indexing and searching for appropriate test script instances.
comment:
  v: When multiple useContexts are specified, there is no expectation that all or any of the contexts apply.
requirements:
  v: Assist in searching for appropriate content.
min:
  v: 0
max:
  v: *
base:
  path:
    v: CanonicalResource.useContext
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: UsageContext
    l: UsageContext
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
must support:
  v: false
is modifier:
  v: false
is summary:
  v: true
mapping:
  identity:
    v: workflow
  map:
    v: Definition.useContext

id:
  v: TestScript.jurisdiction
extension:
  url:
    v: http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status
    l: structuredefinition-standards-status
  value: Code
    v: deprecated
path:
  v: TestScript.jurisdiction
short:
  v: Intended jurisdiction for test script (if applicable)
definition:
  v: A legal or geographic region in which the test script is intended to be used.
comment:
  v: It may be possible for the test script to be used in jurisdictions other than those for which it was originally designed or intended. DEPRECATION NOTE: For consistency, implementations are encouraged to migrate to using the new 'jurisdiction' code in the useContext element. (I.e. useContext.code indicating http://terminology.hl7.org/CodeSystem/usage-context-type#jurisdiction and useContext.valueCodeableConcept indicating the jurisdiction.)
min:
  v: 0
max:
  v: *
base:
  path:
    v: CanonicalResource.jurisdiction
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: CodeableConcept
    l: CodeableConcept
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
must support:
  v: false
is modifier:
  v: false
is summary:
  v: true
binding:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
      l: elementdefinition-bindingName
    value: String
      v: Jurisdiction
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-isCommonBinding
      l: elementdefinition-isCommonBinding
    value: Boolean
      v: true
  strength:
    v: extensible
  description:
    v: Countries and regions within which this artifact is targeted for use.
  value set:
    v: http://hl7.org/fhir/ValueSet/jurisdiction
    l: jurisdiction
mapping:
  identity:
    v: workflow
  map:
    v: Definition.jurisdiction

id:
  v: TestScript.purpose
extension:
  url:
    v: http://hl7.org/fhir/StructureDefinition/elementdefinition-translatable
    l: elementdefinition-translatable
  value: Boolean
    v: true
path:
  v: TestScript.purpose
short:
  v: Why this test script is defined
definition:
  v: Explanation of why this test script is needed and why it has been designed as it has.
comment:
  v: This element does not describe the usage of the test script. Instead, it provides traceability of ''why'' the resource is either needed or ''why'' it is defined as it is. This may be used to point to source materials or specifications that drove the structure of this test script.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: CanonicalResource.purpose
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: markdown
    l: markdown
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
must support:
  v: false
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: workflow
  map:
    v: Definition.purpose
mapping:
  identity:
    v: w5
  map:
    v: FiveWs.why[x]
mapping:
  identity:
    v: objimpl
  map:
    v: no-gen-base

id:
  v: TestScript.copyright
extension:
  url:
    v: http://hl7.org/fhir/StructureDefinition/elementdefinition-translatable
    l: elementdefinition-translatable
  value: Boolean
    v: true
path:
  v: TestScript.copyright
short:
  v: Use and/or publishing restrictions
definition:
  v: A copyright statement relating to the test script and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the test script.
comment:
  v: The short copyright declaration (e.g. (c) '2015+ xyz organization' should be sent in the copyrightLabel element.
requirements:
  v: Consumers must be able to determine any legal restrictions on the use of the test script and/or its content.
alias:
  v: License
alias:
  v: Restrictions
min:
  v: 0
max:
  v: 1
base:
  path:
    v: CanonicalResource.copyright
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: markdown
    l: markdown
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
must support:
  v: false
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: workflow
  map:
    v: Definition.copyright
mapping:
  identity:
    v: objimpl
  map:
    v: no-gen-base

id:
  v: TestScript.copyrightLabel
extension:
  url:
    v: http://hl7.org/fhir/StructureDefinition/elementdefinition-translatable
    l: elementdefinition-translatable
  value: Boolean
    v: true
path:
  v: TestScript.copyrightLabel
short:
  v: Copyright holder and year(s)
definition:
  v: A short string (<50 characters), suitable for inclusion in a page footer that identifies the copyright holder, effective period, and optionally whether rights are resctricted. (e.g. 'All rights reserved', 'Some rights reserved').
comment:
  v: The (c) symbol should NOT be included in this string. It will be added by software when rendering the notation. Full details about licensing, restrictions, warrantees, etc. goes in the more general 'copyright' element.
requirements:
  v: Defines the content expected to be rendered in all representations of the artifact.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: CanonicalResource.copyrightLabel
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
must support:
  v: false
is modifier:
  v: false
is summary:
  v: false

id:
  v: TestScript.testSystem
path:
  v: TestScript.testSystem
short:
  v: An abstract server representing a client or sender in a message exchange
definition:
  v: An abstract server used in operations within this test script in the origin element.
comment:
  v: The purpose of this element is to define the profile of an origin element used elsewhere in the script. Test engines could then use the origin-profile mapping to offer a filtered list of test systems that can serve as the sender for the interaction.
min:
  v: 0
max:
  v: *
base:
  path:
    v: TestScript.testSystem
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: BackboneElement
    l: BackboneElement
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children or both
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element

id:
  v: TestScript.testSystem.id
path:
  v: TestScript.testSystem.id
representation:
  v: xmlAttr
short:
  v: Unique id for inter-element referencing
definition:
  v: Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Element.id
  min:
    v: 0
  max:
    v: 1
type:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
      l: structuredefinition-fhir-type
    value: Url
      v: id
      l: id
  code:
    v: http://hl7.org/fhirpath/System.String
    l: System.String
condition:
  v: ele-1
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.testSystem.extension
path:
  v: TestScript.testSystem.extension
slicing:
  discriminator:
    type:
      v: value
    path:
      v: url
  description:
    v: Extensions are always sliced by (at least) url
  rules:
    v: open
short:
  v: Additional content defined by implementations
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
alias:
  v: extensions
alias:
  v: user content
min:
  v: 0
max:
  v: *
base:
  path:
    v: Element.extension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.testSystem.modifierExtension
path:
  v: TestScript.testSystem.modifierExtension
short:
  v: Extensions that cannot be ignored even if unrecognized
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions. Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
requirements:
  v: Modifier extensions allow for extensions that *cannot* be safely ignored to be clearly distinguished from the vast majority of extensions which can be safely ignored. This promotes interoperability by eliminating the need for implementers to prohibit the presence of extensions. For further information, see the [definition of modifier extensions](http://build.fhir.org/extensibility.html#modifierExtension).
alias:
  v: extensions
alias:
  v: user content
alias:
  v: modifiers
min:
  v: 0
max:
  v: *
base:
  path:
    v: BackboneElement.modifierExtension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: true
is modifier reason:
  v: Modifier extensions are expected to modify the meaning or interpretation of the element that contains them
is summary:
  v: true
mapping:
  identity:
    v: rim
  map:
    v: N/A

id:
  v: TestScript.testSystem.index
path:
  v: TestScript.testSystem.index
short:
  v: The index of the abstract test system
definition:
  v: Number for the test system that is unique within this test script. Referenced by operation.origin and/or operation.destination.
comment:
  v: A given test system index (e.g. 1) can appear only once in the list (e.g. Origin 1 cannot be specified twice ... once as actor A and again as actor B within the same script as that could get confusing during test configuration). Different test system indices could play the same actor in the same test script. The operation.origin and/or operation.destination values defined elsewhere in the test script must be one of these test system indices.
min:
  v: 1
max:
  v: 1
base:
  path:
    v: TestScript.testSystem.index
  min:
    v: 1
  max:
    v: 1
type:
  code:
    v: positiveInt
    l: positiveInt

id:
  v: TestScript.testSystem.title
path:
  v: TestScript.testSystem.title
short:
  v: Label for the test system
definition:
  v: A short human-friendly label for the test system that is unique within this test script and may be used when rendering the script.
min:
  v: 1
max:
  v: 1
base:
  path:
    v: TestScript.testSystem.title
  min:
    v: 1
  max:
    v: 1
type:
  code:
    v: string
    l: string

id:
  v: TestScript.testSystem.actor
path:
  v: TestScript.testSystem.actor
short:
  v: Features met by the test system
definition:
  v: Reference to requirements that must be satisfied by the test system.
min:
  v: 0
max:
  v: *
base:
  path:
    v: TestScript.testSystem.actor
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: canonical
    l: canonical
  target profile:
    v: http://hl7.org/fhir/StructureDefinition/ActorDefinition
    l: ActorDefinition
  target profile:
    v: http://hl7.org/fhir/StructureDefinition/CapabilityStatement
    l: CapabilityStatement

id:
  v: TestScript.testSystem.description
path:
  v: TestScript.testSystem.description
short:
  v: Formatted information of this test system
definition:
  v: Additional information about the role and capabilities of the systems that would participate in this portion of the script.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.testSystem.description
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: markdown
    l: markdown

id:
  v: TestScript.testSystem.url
path:
  v: TestScript.testSystem.url
short:
  v: The url path of this test system
definition:
  v: The explicit url path of the test system used in this test script. If populated, the test engine is not expected to prompt for or accept external input of this value.
comment:
  v: This value represents the host location for an origin test system or the base url for a destination test system.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.testSystem.url
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: url
    l: url

id:
  v: TestScript.metadata
path:
  v: TestScript.metadata
short:
  v: Required capability that is assumed to function correctly on the FHIR server being tested
definition:
  v: The required capability must exist and are assumed to function correctly on the FHIR server being tested.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.metadata
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: BackboneElement
    l: BackboneElement
constraint:
  key:
    v: tst-1
  severity:
    v: error
  human:
    v: TestScript metadata capability SHALL contain required or validated or both.
  expression:
    v: capability.required.exists() or capability.validated.exists()
  source:
    v: http://hl7.org/fhir/StructureDefinition/TestScript
    l: TestScript
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children or both
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element

id:
  v: TestScript.metadata.id
path:
  v: TestScript.metadata.id
representation:
  v: xmlAttr
short:
  v: Unique id for inter-element referencing
definition:
  v: Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Element.id
  min:
    v: 0
  max:
    v: 1
type:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
      l: structuredefinition-fhir-type
    value: Url
      v: id
      l: id
  code:
    v: http://hl7.org/fhirpath/System.String
    l: System.String
condition:
  v: ele-1
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.metadata.extension
path:
  v: TestScript.metadata.extension
slicing:
  discriminator:
    type:
      v: value
    path:
      v: url
  description:
    v: Extensions are always sliced by (at least) url
  rules:
    v: open
short:
  v: Additional content defined by implementations
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
alias:
  v: extensions
alias:
  v: user content
min:
  v: 0
max:
  v: *
base:
  path:
    v: Element.extension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.metadata.modifierExtension
path:
  v: TestScript.metadata.modifierExtension
short:
  v: Extensions that cannot be ignored even if unrecognized
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions. Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
requirements:
  v: Modifier extensions allow for extensions that *cannot* be safely ignored to be clearly distinguished from the vast majority of extensions which can be safely ignored. This promotes interoperability by eliminating the need for implementers to prohibit the presence of extensions. For further information, see the [definition of modifier extensions](http://build.fhir.org/extensibility.html#modifierExtension).
alias:
  v: extensions
alias:
  v: user content
alias:
  v: modifiers
min:
  v: 0
max:
  v: *
base:
  path:
    v: BackboneElement.modifierExtension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: true
is modifier reason:
  v: Modifier extensions are expected to modify the meaning or interpretation of the element that contains them
is summary:
  v: true
mapping:
  identity:
    v: rim
  map:
    v: N/A

id:
  v: TestScript.metadata.link
path:
  v: TestScript.metadata.link
short:
  v: Links to the FHIR specification
definition:
  v: A link to the FHIR specification that this test is covering.
min:
  v: 0
max:
  v: *
base:
  path:
    v: TestScript.metadata.link
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: BackboneElement
    l: BackboneElement
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children or both
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element

id:
  v: TestScript.metadata.link.id
path:
  v: TestScript.metadata.link.id
representation:
  v: xmlAttr
short:
  v: Unique id for inter-element referencing
definition:
  v: Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Element.id
  min:
    v: 0
  max:
    v: 1
type:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
      l: structuredefinition-fhir-type
    value: Url
      v: id
      l: id
  code:
    v: http://hl7.org/fhirpath/System.String
    l: System.String
condition:
  v: ele-1
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.metadata.link.extension
path:
  v: TestScript.metadata.link.extension
slicing:
  discriminator:
    type:
      v: value
    path:
      v: url
  description:
    v: Extensions are always sliced by (at least) url
  rules:
    v: open
short:
  v: Additional content defined by implementations
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
alias:
  v: extensions
alias:
  v: user content
min:
  v: 0
max:
  v: *
base:
  path:
    v: Element.extension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.metadata.link.modifierExtension
path:
  v: TestScript.metadata.link.modifierExtension
short:
  v: Extensions that cannot be ignored even if unrecognized
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions. Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
requirements:
  v: Modifier extensions allow for extensions that *cannot* be safely ignored to be clearly distinguished from the vast majority of extensions which can be safely ignored. This promotes interoperability by eliminating the need for implementers to prohibit the presence of extensions. For further information, see the [definition of modifier extensions](http://build.fhir.org/extensibility.html#modifierExtension).
alias:
  v: extensions
alias:
  v: user content
alias:
  v: modifiers
min:
  v: 0
max:
  v: *
base:
  path:
    v: BackboneElement.modifierExtension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: true
is modifier reason:
  v: Modifier extensions are expected to modify the meaning or interpretation of the element that contains them
is summary:
  v: true
mapping:
  identity:
    v: rim
  map:
    v: N/A

id:
  v: TestScript.metadata.link.url
path:
  v: TestScript.metadata.link.url
short:
  v: URL to the specification
definition:
  v: URL to a particular requirement or feature within the FHIR specification.
min:
  v: 1
max:
  v: 1
base:
  path:
    v: TestScript.metadata.link.url
  min:
    v: 1
  max:
    v: 1
type:
  code:
    v: uri
    l: uri

id:
  v: TestScript.metadata.link.description
path:
  v: TestScript.metadata.link.description
short:
  v: Short description
definition:
  v: Short description of the link.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.metadata.link.description
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string

id:
  v: TestScript.metadata.capability
path:
  v: TestScript.metadata.capability
short:
  v: Capabilities that are assumed to function correctly on the FHIR server being tested
definition:
  v: Capabilities that must exist and are assumed to function correctly on the FHIR server being tested.
comment:
  v: When the metadata capabilities section is defined at TestScript.metadata, and the server's conformance statement does not contain the elements defined in the minimal conformance statement, then all the tests in the TestScript are skipped. The "metadata.capabilities.required" and "metadata.capabilities.validated" elements only indicate whether the capabilities are the primary focus of the test script or not. They do not impact the skipping logic. Capabilities whose "metadata.capabilities.validated" flag is true are the primary focus of the test script.
min:
  v: 1
max:
  v: *
base:
  path:
    v: TestScript.metadata.capability
  min:
    v: 1
  max:
    v: *
type:
  code:
    v: BackboneElement
    l: BackboneElement
condition:
  v: tst-1
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children or both
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element

id:
  v: TestScript.metadata.capability.id
path:
  v: TestScript.metadata.capability.id
representation:
  v: xmlAttr
short:
  v: Unique id for inter-element referencing
definition:
  v: Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Element.id
  min:
    v: 0
  max:
    v: 1
type:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
      l: structuredefinition-fhir-type
    value: Url
      v: id
      l: id
  code:
    v: http://hl7.org/fhirpath/System.String
    l: System.String
condition:
  v: ele-1
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.metadata.capability.extension
path:
  v: TestScript.metadata.capability.extension
slicing:
  discriminator:
    type:
      v: value
    path:
      v: url
  description:
    v: Extensions are always sliced by (at least) url
  rules:
    v: open
short:
  v: Additional content defined by implementations
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
alias:
  v: extensions
alias:
  v: user content
min:
  v: 0
max:
  v: *
base:
  path:
    v: Element.extension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.metadata.capability.modifierExtension
path:
  v: TestScript.metadata.capability.modifierExtension
short:
  v: Extensions that cannot be ignored even if unrecognized
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions. Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
requirements:
  v: Modifier extensions allow for extensions that *cannot* be safely ignored to be clearly distinguished from the vast majority of extensions which can be safely ignored. This promotes interoperability by eliminating the need for implementers to prohibit the presence of extensions. For further information, see the [definition of modifier extensions](http://build.fhir.org/extensibility.html#modifierExtension).
alias:
  v: extensions
alias:
  v: user content
alias:
  v: modifiers
min:
  v: 0
max:
  v: *
base:
  path:
    v: BackboneElement.modifierExtension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: true
is modifier reason:
  v: Modifier extensions are expected to modify the meaning or interpretation of the element that contains them
is summary:
  v: true
mapping:
  identity:
    v: rim
  map:
    v: N/A

id:
  v: TestScript.metadata.capability.required
path:
  v: TestScript.metadata.capability.required
short:
  v: Are the capabilities required?
definition:
  v: Whether or not the test execution will require the given capabilities of the server in order for this test script to execute.
min:
  v: 1
max:
  v: 1
base:
  path:
    v: TestScript.metadata.capability.required
  min:
    v: 1
  max:
    v: 1
type:
  code:
    v: boolean
    l: boolean
condition:
  v: tst-1

id:
  v: TestScript.metadata.capability.validated
path:
  v: TestScript.metadata.capability.validated
short:
  v: Are the capabilities validated?
definition:
  v: Whether or not the test execution will validate the given capabilities of the server in order for this test script to execute.
min:
  v: 1
max:
  v: 1
base:
  path:
    v: TestScript.metadata.capability.validated
  min:
    v: 1
  max:
    v: 1
type:
  code:
    v: boolean
    l: boolean
condition:
  v: tst-1

id:
  v: TestScript.metadata.capability.description
path:
  v: TestScript.metadata.capability.description
short:
  v: The expected capabilities of the server
definition:
  v: Description of the capabilities that this test script is requiring the server to support.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.metadata.capability.description
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string

id:
  v: TestScript.metadata.capability.origin
path:
  v: TestScript.metadata.capability.origin
short:
  v: Which origin server these requirements apply to
definition:
  v: Which origin server these requirements apply to.
min:
  v: 0
max:
  v: *
base:
  path:
    v: TestScript.metadata.capability.origin
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: integer
    l: integer

id:
  v: TestScript.metadata.capability.destination
path:
  v: TestScript.metadata.capability.destination
short:
  v: Which server these requirements apply to
definition:
  v: Which server these requirements apply to.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.metadata.capability.destination
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: integer
    l: integer

id:
  v: TestScript.metadata.capability.link
path:
  v: TestScript.metadata.capability.link
short:
  v: Links to the FHIR specification
definition:
  v: Links to the FHIR specification that describes this interaction and the resources involved in more detail.
min:
  v: 0
max:
  v: *
base:
  path:
    v: TestScript.metadata.capability.link
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: uri
    l: uri

id:
  v: TestScript.metadata.capability.capabilities
path:
  v: TestScript.metadata.capability.capabilities
short:
  v: Required Capability Statement
definition:
  v: Minimum capabilities required of server for test script to execute successfully. If server does not meet at a minimum the referenced capability statement, then all tests in this script are skipped.
comment:
  v: The conformance statement of the server has to contain at a minimum the contents of the reference pointed to by this element.
min:
  v: 1
max:
  v: 1
base:
  path:
    v: TestScript.metadata.capability.capabilities
  min:
    v: 1
  max:
    v: 1
type:
  code:
    v: canonical
    l: canonical
  target profile:
    v: http://hl7.org/fhir/StructureDefinition/CapabilityStatement
    l: CapabilityStatement

id:
  v: TestScript.scope
path:
  v: TestScript.scope
short:
  v: Indication of the artifact(s) that are tested by this test case
definition:
  v: The scope indicates a conformance artifact that is tested by the test(s) within this test case and the expectation of the test outcome(s) as well as the intended test phase inclusion.
min:
  v: 0
max:
  v: *
base:
  path:
    v: TestScript.scope
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: BackboneElement
    l: BackboneElement
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children or both
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element

id:
  v: TestScript.scope.id
path:
  v: TestScript.scope.id
representation:
  v: xmlAttr
short:
  v: Unique id for inter-element referencing
definition:
  v: Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Element.id
  min:
    v: 0
  max:
    v: 1
type:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
      l: structuredefinition-fhir-type
    value: Url
      v: id
      l: id
  code:
    v: http://hl7.org/fhirpath/System.String
    l: System.String
condition:
  v: ele-1
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.scope.extension
path:
  v: TestScript.scope.extension
slicing:
  discriminator:
    type:
      v: value
    path:
      v: url
  description:
    v: Extensions are always sliced by (at least) url
  rules:
    v: open
short:
  v: Additional content defined by implementations
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
alias:
  v: extensions
alias:
  v: user content
min:
  v: 0
max:
  v: *
base:
  path:
    v: Element.extension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.scope.modifierExtension
path:
  v: TestScript.scope.modifierExtension
short:
  v: Extensions that cannot be ignored even if unrecognized
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions. Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
requirements:
  v: Modifier extensions allow for extensions that *cannot* be safely ignored to be clearly distinguished from the vast majority of extensions which can be safely ignored. This promotes interoperability by eliminating the need for implementers to prohibit the presence of extensions. For further information, see the [definition of modifier extensions](http://build.fhir.org/extensibility.html#modifierExtension).
alias:
  v: extensions
alias:
  v: user content
alias:
  v: modifiers
min:
  v: 0
max:
  v: *
base:
  path:
    v: BackboneElement.modifierExtension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: true
is modifier reason:
  v: Modifier extensions are expected to modify the meaning or interpretation of the element that contains them
is summary:
  v: true
mapping:
  identity:
    v: rim
  map:
    v: N/A

id:
  v: TestScript.scope.artifact
path:
  v: TestScript.scope.artifact
short:
  v: The specific conformance artifact being tested
definition:
  v: The specific conformance artifact being tested. The canonical reference can be version-specific.
min:
  v: 1
max:
  v: 1
base:
  path:
    v: TestScript.scope.artifact
  min:
    v: 1
  max:
    v: 1
type:
  code:
    v: canonical
    l: canonical
  target profile:
    v: http://hl7.org/fhir/StructureDefinition/Resource
    l: Resource

id:
  v: TestScript.scope.conformance
path:
  v: TestScript.scope.conformance
short:
  v: required | optional | strict
definition:
  v: The expectation of whether the test must pass for the system to be considered conformant with the artifact: required - all tests are expected to pass, optional - all test are expected to pass but non-pass status may be allowed, strict - all tests are expected to pass and warnings are treated as a failure.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.scope.conformance
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: CodeableConcept
    l: CodeableConcept
meaning when missing:
  v: required
binding:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
      l: elementdefinition-bindingName
    value: String
      v: TestScriptScopeConformanceType
  extension:
    url:
      v: http://hl7.org/fhir/tools/StructureDefinition/binding-definition
      l: binding-definition
    value: Markdown
      v: The expectation of whether the test must pass for the system to be considered conformant with the artifact.
  strength:
    v: extensible
  description:
    v: The expectation of whether the test must pass for the system to be considered conformant with the artifact.
  value set:
    v: http://hl7.org/fhir/ValueSet/testscript-scope-conformance-codes
    l: testscript-scope-conformance-codes

id:
  v: TestScript.scope.phase
path:
  v: TestScript.scope.phase
short:
  v: unit | integration | production
definition:
  v: The phase of testing for this artifact: unit - development / implementation phase, integration - internal system to system phase, production - live system to system phase (Note, this may involve pii/phi data).
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.scope.phase
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: CodeableConcept
    l: CodeableConcept
meaning when missing:
  v: unit
binding:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
      l: elementdefinition-bindingName
    value: String
      v: TestScriptScopePhaseType
  extension:
    url:
      v: http://hl7.org/fhir/tools/StructureDefinition/binding-definition
      l: binding-definition
    value: Markdown
      v: The phase of testing for this artifact.
  strength:
    v: extensible
  description:
    v: The phase of testing for this artifact.
  value set:
    v: http://hl7.org/fhir/ValueSet/testscript-scope-phase-codes
    l: testscript-scope-phase-codes

id:
  v: TestScript.fixture
path:
  v: TestScript.fixture
short:
  v: Fixture in the test script - by reference (uri)
definition:
  v: Fixture in the test script - by reference (uri). All fixtures are required for the test script to execute.
min:
  v: 0
max:
  v: *
base:
  path:
    v: TestScript.fixture
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: BackboneElement
    l: BackboneElement
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children or both
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element

id:
  v: TestScript.fixture.id
path:
  v: TestScript.fixture.id
representation:
  v: xmlAttr
short:
  v: Unique id for inter-element referencing
definition:
  v: Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Element.id
  min:
    v: 0
  max:
    v: 1
type:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
      l: structuredefinition-fhir-type
    value: Url
      v: id
      l: id
  code:
    v: http://hl7.org/fhirpath/System.String
    l: System.String
condition:
  v: ele-1
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.fixture.extension
path:
  v: TestScript.fixture.extension
slicing:
  discriminator:
    type:
      v: value
    path:
      v: url
  description:
    v: Extensions are always sliced by (at least) url
  rules:
    v: open
short:
  v: Additional content defined by implementations
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
alias:
  v: extensions
alias:
  v: user content
min:
  v: 0
max:
  v: *
base:
  path:
    v: Element.extension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.fixture.modifierExtension
path:
  v: TestScript.fixture.modifierExtension
short:
  v: Extensions that cannot be ignored even if unrecognized
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions. Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
requirements:
  v: Modifier extensions allow for extensions that *cannot* be safely ignored to be clearly distinguished from the vast majority of extensions which can be safely ignored. This promotes interoperability by eliminating the need for implementers to prohibit the presence of extensions. For further information, see the [definition of modifier extensions](http://build.fhir.org/extensibility.html#modifierExtension).
alias:
  v: extensions
alias:
  v: user content
alias:
  v: modifiers
min:
  v: 0
max:
  v: *
base:
  path:
    v: BackboneElement.modifierExtension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: true
is modifier reason:
  v: Modifier extensions are expected to modify the meaning or interpretation of the element that contains them
is summary:
  v: true
mapping:
  identity:
    v: rim
  map:
    v: N/A

id:
  v: TestScript.fixture.autocreate
path:
  v: TestScript.fixture.autocreate
short:
  v: Whether or not to implicitly create the fixture during setup
definition:
  v: Whether or not to implicitly create the fixture during setup. If true, the fixture is automatically created on each server being tested during setup, therefore no create operation is required for this fixture in the TestScript.setup section.
min:
  v: 1
max:
  v: 1
base:
  path:
    v: TestScript.fixture.autocreate
  min:
    v: 1
  max:
    v: 1
type:
  code:
    v: boolean
    l: boolean

id:
  v: TestScript.fixture.autodelete
path:
  v: TestScript.fixture.autodelete
short:
  v: Whether or not to implicitly delete the fixture during teardown
definition:
  v: Whether or not to implicitly delete the fixture during teardown. If true, the fixture is automatically deleted on each server being tested during teardown, therefore no delete operation is required for this fixture in the TestScript.teardown section.
min:
  v: 1
max:
  v: 1
base:
  path:
    v: TestScript.fixture.autodelete
  min:
    v: 1
  max:
    v: 1
type:
  code:
    v: boolean
    l: boolean

id:
  v: TestScript.fixture.resource
path:
  v: TestScript.fixture.resource
short:
  v: Reference of the resource
definition:
  v: Reference to the resource (containing the contents of the resource needed for operations). This is allowed to be a Parameters resource.
comment:
  v: See the [Resource List](http://hl7.org/fhir/R5/resourcelist.html) for complete list of resource types.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.fixture.resource
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: Reference
    l: Reference
  target profile:
    v: http://hl7.org/fhir/StructureDefinition/Resource
    l: Resource

id:
  v: TestScript.fixture.expression
path:
  v: TestScript.fixture.expression
short:
  v: The expression against the fixture to extract the required element
definition:
  v: The expression for a specific element to extract from the fixture body.
comment:
  v: If expression is defined then the evaluated element from the fixture will become the fixture contents. A test engine is expected to minimally support the expression languages: text/fhirpath, application/xml and application/json.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.fixture.expression
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: Expression
    l: Expression

id:
  v: TestScript.profile
path:
  v: TestScript.profile
short:
  v: Reference of the validation profile
definition:
  v: Reference to the profile to be used for validation.
comment:
  v: See the [Resource List](http://hl7.org/fhir/R5/resourcelist.html) for complete list of resource types.
min:
  v: 0
max:
  v: *
base:
  path:
    v: TestScript.profile
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: canonical
    l: canonical
  target profile:
    v: http://hl7.org/fhir/StructureDefinition/StructureDefinition
    l: StructureDefinition

id:
  v: TestScript.variable
path:
  v: TestScript.variable
short:
  v: Placeholder for evaluated elements
definition:
  v: Variable is set based either on element value in response body or on header field value in the response headers.
comment:
  v: Variables would be set based either on XPath/JSONPath expressions against fixtures (static and response), or headerField evaluations against response headers. If variable evaluates to nodelist or anything other than a primitive value, then test engine would report an error. Variables would be used to perform clean replacements in "operation.params", "operation.requestHeader.value", and "operation.url" element values during operation calls and in "assert.value" during assertion evaluations. This limits the places that test engines would need to look for placeholders "${}". Variables are scoped to the whole script. They are NOT evaluated at declaration. They are evaluated by test engine when used for substitutions in "operation.params", "operation.requestHeader.value", and "operation.url" element values during operation calls and in "assert.value" during assertion evaluations. See example testscript-search.xml.
min:
  v: 0
max:
  v: *
base:
  path:
    v: TestScript.variable
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: BackboneElement
    l: BackboneElement
constraint:
  key:
    v: tst-2
  severity:
    v: error
  human:
    v: Variable can only contain one of expression, headerField or path.
  expression:
    v: (expression.empty() and headerField.empty() and path.empty()) or (expression.empty() and (headerField.exists() xor path.exists())) or (headerField.empty() and (expression.exists() xor path.exists())) or (path.empty() and (expression.exists() xor headerField.exists()))
  source:
    v: http://hl7.org/fhir/StructureDefinition/TestScript
    l: TestScript
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children or both
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element

id:
  v: TestScript.variable.id
path:
  v: TestScript.variable.id
representation:
  v: xmlAttr
short:
  v: Unique id for inter-element referencing
definition:
  v: Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Element.id
  min:
    v: 0
  max:
    v: 1
type:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
      l: structuredefinition-fhir-type
    value: Url
      v: id
      l: id
  code:
    v: http://hl7.org/fhirpath/System.String
    l: System.String
condition:
  v: ele-1
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.variable.extension
path:
  v: TestScript.variable.extension
slicing:
  discriminator:
    type:
      v: value
    path:
      v: url
  description:
    v: Extensions are always sliced by (at least) url
  rules:
    v: open
short:
  v: Additional content defined by implementations
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
alias:
  v: extensions
alias:
  v: user content
min:
  v: 0
max:
  v: *
base:
  path:
    v: Element.extension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.variable.modifierExtension
path:
  v: TestScript.variable.modifierExtension
short:
  v: Extensions that cannot be ignored even if unrecognized
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions. Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
requirements:
  v: Modifier extensions allow for extensions that *cannot* be safely ignored to be clearly distinguished from the vast majority of extensions which can be safely ignored. This promotes interoperability by eliminating the need for implementers to prohibit the presence of extensions. For further information, see the [definition of modifier extensions](http://build.fhir.org/extensibility.html#modifierExtension).
alias:
  v: extensions
alias:
  v: user content
alias:
  v: modifiers
min:
  v: 0
max:
  v: *
base:
  path:
    v: BackboneElement.modifierExtension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: true
is modifier reason:
  v: Modifier extensions are expected to modify the meaning or interpretation of the element that contains them
is summary:
  v: true
mapping:
  identity:
    v: rim
  map:
    v: N/A

id:
  v: TestScript.variable.name
path:
  v: TestScript.variable.name
short:
  v: Descriptive name for this variable
definition:
  v: Descriptive name for this variable.
comment:
  v: Placeholders would contain the variable name wrapped in ${} in "operation.params", "operation.requestHeader.value", and "operation.url" elements. These placeholders would need to be replaced by the variable value before the operation is executed.
min:
  v: 1
max:
  v: 1
base:
  path:
    v: TestScript.variable.name
  min:
    v: 1
  max:
    v: 1
type:
  code:
    v: string
    l: string

id:
  v: TestScript.variable.defaultValue
path:
  v: TestScript.variable.defaultValue
short:
  v: Default, hard-coded, or user-defined value for this variable
definition:
  v: A default, hard-coded, or user-defined value for this variable.
comment:
  v: The purpose of this element is to allow for a pre-defined value that can be used as a default or as an override value. Test engines can optionally use this as a placeholder for user-defined execution time values.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.variable.defaultValue
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string

id:
  v: TestScript.variable.description
path:
  v: TestScript.variable.description
short:
  v: Natural language description of the variable
definition:
  v: A free text natural language description of the variable and its purpose.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.variable.description
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string

id:
  v: TestScript.variable.expression
path:
  v: TestScript.variable.expression
short:
  v: The expression against the fixture body
definition:
  v: The expression for a specific value to evaluate against the fixture body. When variables are defined, only one of either expression, headerField or path must be specified.
comment:
  v: If headerField is defined, then the variable will be evaluated against the headers that sourceId is pointing to. If expression or path is defined, then the variable will be evaluated against the fixture body that sourceId is pointing to. It is an error to define any combination of expression, headerField and path. A test engine is expected to minimally support the expression languages: text/fhirpath, application/xml and application/json.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.variable.expression
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: Expression
    l: Expression
condition:
  v: tst-2

id:
  v: TestScript.variable.headerField
path:
  v: TestScript.variable.headerField
short:
  v: HTTP header field name for source
definition:
  v: Will be used to grab the HTTP header field value from the headers that sourceId is pointing to.
comment:
  v: If headerField is defined, then the variable will be evaluated against the headers that sourceId is pointing to. If path is defined, then the variable will be evaluated against the fixture body that sourceId is pointing to. It is an error to define both headerField and path.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.variable.headerField
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string
condition:
  v: tst-2

id:
  v: TestScript.variable.hint
path:
  v: TestScript.variable.hint
short:
  v: Hint help text for default value to enter
definition:
  v: Displayable text string with hint help information to the user when entering a default value.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.variable.hint
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string

id:
  v: TestScript.variable.path
extension:
  url:
    v: http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status
    l: structuredefinition-standards-status
  value: Code
    v: deprecated
path:
  v: TestScript.variable.path
short:
  v: XPath or JSONPath against the fixture body
definition:
  v: XPath or JSONPath to evaluate against the fixture body. When variables are defined, only one of either expression, headerField or path must be specified.
comment:
  v: If headerField is defined, then the variable will be evaluated against the headers that sourceId is pointing to. If expression or path is defined, then the variable will be evaluated against the fixture body that sourceId is pointing to. It is an error to define any combination of expression, headerField and path.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.variable.path
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string
condition:
  v: tst-2

id:
  v: TestScript.variable.sourceId
path:
  v: TestScript.variable.sourceId
short:
  v: Fixture Id of source expression or headerField within this variable
definition:
  v: Fixture to evaluate the XPath/JSONPath expression or the headerField against within this variable.
comment:
  v: This can be a statically defined fixture (at the top of the TestScript) or a dynamically set fixture created by responseId of the `action.operation` element.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.variable.sourceId
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: id
    l: id

id:
  v: TestScript.setup
path:
  v: TestScript.setup
short:
  v: A series of required setup operations before tests are executed
definition:
  v: A series of required setup operations before tests are executed.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: BackboneElement
    l: BackboneElement
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children or both
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element

id:
  v: TestScript.setup.id
path:
  v: TestScript.setup.id
representation:
  v: xmlAttr
short:
  v: Unique id for inter-element referencing
definition:
  v: Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Element.id
  min:
    v: 0
  max:
    v: 1
type:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
      l: structuredefinition-fhir-type
    value: Url
      v: id
      l: id
  code:
    v: http://hl7.org/fhirpath/System.String
    l: System.String
condition:
  v: ele-1
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.setup.extension
path:
  v: TestScript.setup.extension
slicing:
  discriminator:
    type:
      v: value
    path:
      v: url
  description:
    v: Extensions are always sliced by (at least) url
  rules:
    v: open
short:
  v: Additional content defined by implementations
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
alias:
  v: extensions
alias:
  v: user content
min:
  v: 0
max:
  v: *
base:
  path:
    v: Element.extension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.setup.modifierExtension
path:
  v: TestScript.setup.modifierExtension
short:
  v: Extensions that cannot be ignored even if unrecognized
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions. Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
requirements:
  v: Modifier extensions allow for extensions that *cannot* be safely ignored to be clearly distinguished from the vast majority of extensions which can be safely ignored. This promotes interoperability by eliminating the need for implementers to prohibit the presence of extensions. For further information, see the [definition of modifier extensions](http://build.fhir.org/extensibility.html#modifierExtension).
alias:
  v: extensions
alias:
  v: user content
alias:
  v: modifiers
min:
  v: 0
max:
  v: *
base:
  path:
    v: BackboneElement.modifierExtension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: true
is modifier reason:
  v: Modifier extensions are expected to modify the meaning or interpretation of the element that contains them
is summary:
  v: true
mapping:
  identity:
    v: rim
  map:
    v: N/A

id:
  v: TestScript.setup.action
extension:
  url:
    v: http://hl7.org/fhir/StructureDefinition/structuredefinition-explicit-type-name
    l: structuredefinition-explicit-type-name
  value: String
    v: SetupAction
path:
  v: TestScript.setup.action
short:
  v: A setup common or operation or assert to perform
definition:
  v: Action would contain either a common or operation or an assertion.
comment:
  v: An action should contain only one of either a common or operation or an assertion. It can contain any number of variables.
min:
  v: 0
max:
  v: *
base:
  path:
    v: TestScript.setup.action
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: BackboneElement
    l: BackboneElement
constraint:
  key:
    v: tst-3
  severity:
    v: error
  human:
    v: Setup action SHALL contain only one of either a common or an operation or an assert.
  expression:
    v: common.exists() xor operation.exists() xor assert.exists()
  source:
    v: http://hl7.org/fhir/StructureDefinition/TestScript
    l: TestScript
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children or both
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element

id:
  v: TestScript.setup.action.id
path:
  v: TestScript.setup.action.id
representation:
  v: xmlAttr
short:
  v: Unique id for inter-element referencing
definition:
  v: Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Element.id
  min:
    v: 0
  max:
    v: 1
type:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
      l: structuredefinition-fhir-type
    value: Url
      v: id
      l: id
  code:
    v: http://hl7.org/fhirpath/System.String
    l: System.String
condition:
  v: ele-1
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.setup.action.extension
path:
  v: TestScript.setup.action.extension
slicing:
  discriminator:
    type:
      v: value
    path:
      v: url
  description:
    v: Extensions are always sliced by (at least) url
  rules:
    v: open
short:
  v: Additional content defined by implementations
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
alias:
  v: extensions
alias:
  v: user content
min:
  v: 0
max:
  v: *
base:
  path:
    v: Element.extension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.setup.action.modifierExtension
path:
  v: TestScript.setup.action.modifierExtension
short:
  v: Extensions that cannot be ignored even if unrecognized
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions. Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
requirements:
  v: Modifier extensions allow for extensions that *cannot* be safely ignored to be clearly distinguished from the vast majority of extensions which can be safely ignored. This promotes interoperability by eliminating the need for implementers to prohibit the presence of extensions. For further information, see the [definition of modifier extensions](http://build.fhir.org/extensibility.html#modifierExtension).
alias:
  v: extensions
alias:
  v: user content
alias:
  v: modifiers
min:
  v: 0
max:
  v: *
base:
  path:
    v: BackboneElement.modifierExtension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: true
is modifier reason:
  v: Modifier extensions are expected to modify the meaning or interpretation of the element that contains them
is summary:
  v: true
mapping:
  identity:
    v: rim
  map:
    v: N/A

id:
  v: TestScript.setup.action.common
extension:
  url:
    v: http://hl7.org/fhir/StructureDefinition/structuredefinition-explicit-type-name
    l: structuredefinition-explicit-type-name
  value: String
    v: SetupActionCommon
path:
  v: TestScript.setup.action.common
short:
  v: Links or references to common collection(s) of actions
definition:
  v: Links or references to common collection(s) of actions in this or an external TestScript instance.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.common
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: BackboneElement
    l: BackboneElement
condition:
  v: tst-3
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children or both
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element

id:
  v: TestScript.setup.action.common.id
path:
  v: TestScript.setup.action.common.id
representation:
  v: xmlAttr
short:
  v: Unique id for inter-element referencing
definition:
  v: Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Element.id
  min:
    v: 0
  max:
    v: 1
type:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
      l: structuredefinition-fhir-type
    value: Url
      v: id
      l: id
  code:
    v: http://hl7.org/fhirpath/System.String
    l: System.String
condition:
  v: ele-1
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.setup.action.common.extension
path:
  v: TestScript.setup.action.common.extension
slicing:
  discriminator:
    type:
      v: value
    path:
      v: url
  description:
    v: Extensions are always sliced by (at least) url
  rules:
    v: open
short:
  v: Additional content defined by implementations
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
alias:
  v: extensions
alias:
  v: user content
min:
  v: 0
max:
  v: *
base:
  path:
    v: Element.extension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.setup.action.common.modifierExtension
path:
  v: TestScript.setup.action.common.modifierExtension
short:
  v: Extensions that cannot be ignored even if unrecognized
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions. Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
requirements:
  v: Modifier extensions allow for extensions that *cannot* be safely ignored to be clearly distinguished from the vast majority of extensions which can be safely ignored. This promotes interoperability by eliminating the need for implementers to prohibit the presence of extensions. For further information, see the [definition of modifier extensions](http://build.fhir.org/extensibility.html#modifierExtension).
alias:
  v: extensions
alias:
  v: user content
alias:
  v: modifiers
min:
  v: 0
max:
  v: *
base:
  path:
    v: BackboneElement.modifierExtension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: true
is modifier reason:
  v: Modifier extensions are expected to modify the meaning or interpretation of the element that contains them
is summary:
  v: true
mapping:
  identity:
    v: rim
  map:
    v: N/A

id:
  v: TestScript.setup.action.common.testScript
path:
  v: TestScript.setup.action.common.testScript
short:
  v: Canonical reference to the common TestScript instance
definition:
  v: Canonical reference providing traceability to the common TestScript instance containing the commonKey.
comment:
  v: If not defined, this TestScript instance is the container of the setup common key.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.common.testScript
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: canonical
    l: canonical
  target profile:
    v: http://hl7.org/fhir/StructureDefinition/TestScript
    l: TestScript

id:
  v: TestScript.setup.action.common.keyRef
path:
  v: TestScript.setup.action.common.keyRef
short:
  v: Common key reference that identifies the common collection of actions to perform
definition:
  v: Common key reference that identifies the common collection of actions to perform as defined the this or the common testScript.
min:
  v: 1
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.common.keyRef
  min:
    v: 1
  max:
    v: 1
type:
  code:
    v: id
    l: id

id:
  v: TestScript.setup.action.common.parameter
extension:
  url:
    v: http://hl7.org/fhir/StructureDefinition/structuredefinition-explicit-type-name
    l: structuredefinition-explicit-type-name
  value: String
    v: SetupActionCommonParameter
path:
  v: TestScript.setup.action.common.parameter
short:
  v: Parameter(s) to convey input values to the identified common collection of actions
definition:
  v: Optional named parameter(s) to provide input values to the identified common collection of actions from this or an external TestScript.
min:
  v: 0
max:
  v: *
base:
  path:
    v: TestScript.setup.action.common.parameter
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: BackboneElement
    l: BackboneElement
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children or both
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element

id:
  v: TestScript.setup.action.common.parameter.id
path:
  v: TestScript.setup.action.common.parameter.id
representation:
  v: xmlAttr
short:
  v: Unique id for inter-element referencing
definition:
  v: Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Element.id
  min:
    v: 0
  max:
    v: 1
type:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
      l: structuredefinition-fhir-type
    value: Url
      v: id
      l: id
  code:
    v: http://hl7.org/fhirpath/System.String
    l: System.String
condition:
  v: ele-1
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.setup.action.common.parameter.extension
path:
  v: TestScript.setup.action.common.parameter.extension
slicing:
  discriminator:
    type:
      v: value
    path:
      v: url
  description:
    v: Extensions are always sliced by (at least) url
  rules:
    v: open
short:
  v: Additional content defined by implementations
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
alias:
  v: extensions
alias:
  v: user content
min:
  v: 0
max:
  v: *
base:
  path:
    v: Element.extension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.setup.action.common.parameter.modifierExtension
path:
  v: TestScript.setup.action.common.parameter.modifierExtension
short:
  v: Extensions that cannot be ignored even if unrecognized
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions. Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
requirements:
  v: Modifier extensions allow for extensions that *cannot* be safely ignored to be clearly distinguished from the vast majority of extensions which can be safely ignored. This promotes interoperability by eliminating the need for implementers to prohibit the presence of extensions. For further information, see the [definition of modifier extensions](http://build.fhir.org/extensibility.html#modifierExtension).
alias:
  v: extensions
alias:
  v: user content
alias:
  v: modifiers
min:
  v: 0
max:
  v: *
base:
  path:
    v: BackboneElement.modifierExtension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: true
is modifier reason:
  v: Modifier extensions are expected to modify the meaning or interpretation of the element that contains them
is summary:
  v: true
mapping:
  identity:
    v: rim
  map:
    v: N/A

id:
  v: TestScript.setup.action.common.parameter.name
path:
  v: TestScript.setup.action.common.parameter.name
short:
  v: Name of the parameter from the identified common collection of actions
definition:
  v: The name of this parameter from the identified common collection of actions from this or an external TestScript.
min:
  v: 1
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.common.parameter.name
  min:
    v: 1
  max:
    v: 1
type:
  code:
    v: string
    l: string

id:
  v: TestScript.setup.action.common.parameter.value
path:
  v: TestScript.setup.action.common.parameter.value
short:
  v: Value to assign to the parameter from the identified common collection of actions
definition:
  v: The value to assign to this parameter from the identified common collection of actions from this or an external TestScript.
comment:
  v: The value data type is a generic string where the expectation is the actual value may be assigned to any action.opertion or action.assert element. The FHIR test engine must correctly assign the value to the target element's data type.
min:
  v: 1
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.common.parameter.value
  min:
    v: 1
  max:
    v: 1
type:
  code:
    v: string
    l: string

id:
  v: TestScript.setup.action.operation
path:
  v: TestScript.setup.action.operation
short:
  v: The setup operation to perform
definition:
  v: The operation to perform.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.operation
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: BackboneElement
    l: BackboneElement
condition:
  v: tst-3
constraint:
  key:
    v: tst-4
  severity:
    v: error
  human:
    v: Setup operation SHALL contain either sourceId or targetId or params or url.
  expression:
    v: sourceId.exists() or (targetId.count() + url.count() + params.count() = 1) or (type.code in ('capabilities' |'search' | 'transaction' | 'history'))
  source:
    v: http://hl7.org/fhir/StructureDefinition/TestScript
    l: TestScript
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children or both
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element

id:
  v: TestScript.setup.action.operation.id
path:
  v: TestScript.setup.action.operation.id
representation:
  v: xmlAttr
short:
  v: Unique id for inter-element referencing
definition:
  v: Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Element.id
  min:
    v: 0
  max:
    v: 1
type:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
      l: structuredefinition-fhir-type
    value: Url
      v: id
      l: id
  code:
    v: http://hl7.org/fhirpath/System.String
    l: System.String
condition:
  v: ele-1
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.setup.action.operation.extension
path:
  v: TestScript.setup.action.operation.extension
slicing:
  discriminator:
    type:
      v: value
    path:
      v: url
  description:
    v: Extensions are always sliced by (at least) url
  rules:
    v: open
short:
  v: Additional content defined by implementations
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
alias:
  v: extensions
alias:
  v: user content
min:
  v: 0
max:
  v: *
base:
  path:
    v: Element.extension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.setup.action.operation.modifierExtension
path:
  v: TestScript.setup.action.operation.modifierExtension
short:
  v: Extensions that cannot be ignored even if unrecognized
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions. Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
requirements:
  v: Modifier extensions allow for extensions that *cannot* be safely ignored to be clearly distinguished from the vast majority of extensions which can be safely ignored. This promotes interoperability by eliminating the need for implementers to prohibit the presence of extensions. For further information, see the [definition of modifier extensions](http://build.fhir.org/extensibility.html#modifierExtension).
alias:
  v: extensions
alias:
  v: user content
alias:
  v: modifiers
min:
  v: 0
max:
  v: *
base:
  path:
    v: BackboneElement.modifierExtension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: true
is modifier reason:
  v: Modifier extensions are expected to modify the meaning or interpretation of the element that contains them
is summary:
  v: true
mapping:
  identity:
    v: rim
  map:
    v: N/A

id:
  v: TestScript.setup.action.operation.type
path:
  v: TestScript.setup.action.operation.type
short:
  v: The operation code type that will be executed
definition:
  v: Server interaction or operation type.
comment:
  v: See the list of [server interactions](http://build.fhir.org/http.html).
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.operation.type
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: Coding
    l: Coding
condition:
  v: tst-4
binding:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
      l: elementdefinition-bindingName
    value: String
      v: TestScriptOperationCode
  extension:
    url:
      v: http://hl7.org/fhir/tools/StructureDefinition/binding-definition
      l: binding-definition
    value: Markdown
      v: The allowable operation code types.
  strength:
    v: extensible
  description:
    v: FHIR Operation Code Types
  value set:
    v: http://hl7.org/fhir/ValueSet/testscript-operation-codes
    l: testscript-operation-codes

id:
  v: TestScript.setup.action.operation.resource
path:
  v: TestScript.setup.action.operation.resource
short:
  v: Resource type
definition:
  v: The type of the FHIR resource. See the [resource list](http://hl7.org/fhir/R5/resourcelist.html). Data type of uri is needed when non-HL7 artifacts are identified.
comment:
  v: If "url" element is specified, then "targetId", "params", and "resource" elements will be ignored as "url" element will have everything needed for constructing the request url. If "params" element is specified, then "targetId" element is ignored. For FHIR operations that require a resource (e.g. "read" and "vread" operations), the "resource" element must be specified when "params" element is specified. If "url" and "params" elements are absent, then the request url will be constructed from "targetId" fixture if present. For "read" operation, the resource and id values will be extracted from "targetId" fixture and used to construct the url. For "vread" and "history" operations, the versionId value will also be used.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.operation.resource
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: uri
    l: uri
binding:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
      l: elementdefinition-bindingName
    value: String
      v: FHIRConcreteTypes
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-isCommonBinding
      l: elementdefinition-isCommonBinding
    value: Boolean
      v: true
  strength:
    v: extensible
  description:
    v: A list of all the concrete types defined in this version of the FHIR specification - Data Types and Resource Types.
  value set:
    v: http://hl7.org/fhir/ValueSet/concrete-fhir-types
    l: concrete-fhir-types

id:
  v: TestScript.setup.action.operation.label
path:
  v: TestScript.setup.action.operation.label
short:
  v: Tracking/logging operation label
definition:
  v: The label would be used for tracking/logging purposes by test engines.
comment:
  v: This has no impact on the verification itself.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.operation.label
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string

id:
  v: TestScript.setup.action.operation.description
path:
  v: TestScript.setup.action.operation.description
short:
  v: Tracking/reporting operation description
definition:
  v: The description would be used by test engines for tracking and reporting purposes.
comment:
  v: This has no impact on the verification itself.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.operation.description
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string

id:
  v: TestScript.setup.action.operation.accept
path:
  v: TestScript.setup.action.operation.accept
short:
  v: Mime type to accept in the payload of the response, with charset etc
definition:
  v: The mime-type to use for RESTful operation in the 'Accept' header.
comment:
  v: If this is specified, then test engine shall set the 'Accept' header to the corresponding value. If you'd like to explicitly set the 'Accept' to some other value then use the 'requestHeader' element.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.operation.accept
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: code
    l: code
example:
  label:
    v: General
  value: Code
    v: application/fhir+xml
binding:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
      l: elementdefinition-bindingName
    value: String
      v: SupplementedMimeType
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-isCommonBinding
      l: elementdefinition-isCommonBinding
    value: Boolean
      v: true
  strength:
    v: required
  description:
    v: The mime type of an attachment. Any valid mime type is allowed (BCP 13; RFCs 2045, 2046, 2047, 4288, 4289 and 2049), and also `json`, `xml`, and `ttl`.
  value set:
    v: http://hl7.org/fhir/ValueSet/supplemented-mimetypes
    l: supplemented-mimetypes
  additional:
    purpose:
      v: starter
    value set:
      v: http://hl7.org/fhir/ValueSet/capability-format-type
      l: capability-format-type

id:
  v: TestScript.setup.action.operation.contentType
path:
  v: TestScript.setup.action.operation.contentType
short:
  v: Mime type of the request payload contents, with charset etc
definition:
  v: The mime-type to use for RESTful operation in the 'Content-Type' header.
comment:
  v: If this is specified, then test engine shall set the 'Content-Type' header to the corresponding value. If you'd like to explicitly set the 'Content-Type' to some other value then use the 'requestHeader' element.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.operation.contentType
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: code
    l: code
example:
  label:
    v: General
  value: Code
    v: application/fhir+xml
binding:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
      l: elementdefinition-bindingName
    value: String
      v: SupplementedMimeType
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-isCommonBinding
      l: elementdefinition-isCommonBinding
    value: Boolean
      v: true
  strength:
    v: required
  description:
    v: The mime type of an attachment. Any valid mime type is allowed (BCP 13; RFCs 2045, 2046, 2047, 4288, 4289 and 2049), and also `json`, `xml`, and `ttl`.
  value set:
    v: http://hl7.org/fhir/ValueSet/supplemented-mimetypes
    l: supplemented-mimetypes
  additional:
    purpose:
      v: starter
    value set:
      v: http://hl7.org/fhir/ValueSet/capability-format-type
      l: capability-format-type

id:
  v: TestScript.setup.action.operation.destination
path:
  v: TestScript.setup.action.operation.destination
short:
  v: Server responding to the request
definition:
  v: The test system where the request message is destined. Must be one of the test system indices listed in TestScript.testSystem section.
comment:
  v: If multiple TestScript.testSystem elements are defined and operation.destination is undefined, the test engine will report an error as it cannot determine what destination test system to use for the exchange.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.operation.destination
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: integer
    l: integer

id:
  v: TestScript.setup.action.operation.encodeRequestUrl
path:
  v: TestScript.setup.action.operation.encodeRequestUrl
short:
  v: Whether or not to send the request url in encoded format
definition:
  v: Whether or not to implicitly send the request url in encoded format. The default is true to match the standard RESTful client behavior. Set to false when communicating with a server that does not support encoded url paths.
min:
  v: 1
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.operation.encodeRequestUrl
  min:
    v: 1
  max:
    v: 1
type:
  code:
    v: boolean
    l: boolean

id:
  v: TestScript.setup.action.operation.method
path:
  v: TestScript.setup.action.operation.method
short:
  v: delete | get | options | patch | post | put | head
definition:
  v: The HTTP method the test engine MUST use for this operation regardless of any other operation details.
comment:
  v: The primary purpose of the explicit HTTP method is support of HTTP POST method invocation of the FHIR search. Other uses will include support of negative testing.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.operation.method
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: code
    l: code
binding:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
      l: elementdefinition-bindingName
    value: String
      v: TestScriptRequestMethodCode
  strength:
    v: required
  description:
    v: The allowable request method or HTTP operation codes.
  value set:
    v: http://hl7.org/fhir/ValueSet/http-operations
    l: http-operations

id:
  v: TestScript.setup.action.operation.origin
path:
  v: TestScript.setup.action.operation.origin
short:
  v: Server initiating the request
definition:
  v: The test system where the request message originates. Must be one of the test system indices listed in TestScript.testSystem section.
comment:
  v: If absent, the test engine will send the message. When present, the test engine will not send the request message but will wait for the request message to be sent from this test system.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.operation.origin
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: integer
    l: integer

id:
  v: TestScript.setup.action.operation.params
path:
  v: TestScript.setup.action.operation.params
short:
  v: Explicitly defined path parameters
definition:
  v: Path plus parameters after [type]. Used to set parts of the request URL explicitly.
comment:
  v: If "url" element is specified, then "targetId", "params", and "resource" elements will be ignored as "url" element will have everything needed for constructing the request url. If "params" element is specified, then "targetId" element is ignored. For FHIR operations that require a resource (e.g. "read" and "vread" operations), the "resource" element must be specified when "params" element is specified. If "url" and "params" elements are absent, then the request url will be constructed from "targetId" fixture if present. For "read" operation, the resource and id values will be extracted from "targetId" fixture and used to construct the url. For "vread" and "history" operations, the versionId value will also be used. Test engines would append whatever is specified for "params" to the URL after the resource type without tampering with the string (beyond encoding the URL for HTTP). The "params" element does not correspond exactly to "search parameters". Nor is it the "path". It corresponds to the part of the URL that comes after the [type] (when "resource" element is specified); e.g. It corresponds to "/[id]/_history/[vid] {?_format=[mime-type]}" in the following operation: GET [base]/[type]/[id]/_history/[vid] {?_format=[mime-type]} Test engines do have to look for placeholders (${}) and replace the variable placeholders with the variable values at runtime before sending the request.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.operation.params
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string
condition:
  v: tst-4

id:
  v: TestScript.setup.action.operation.requestHeader
path:
  v: TestScript.setup.action.operation.requestHeader
short:
  v: Each operation can have one or more header elements
definition:
  v: Header elements would be used to set HTTP headers.
comment:
  v: This gives control to test-script writers to set headers explicitly based on test requirements. It will allow for testing using: - "If-Modified-Since" and "If-None-Match" headers. ["If-Match" header](http://build.fhir.org/http.html#2.1.0.5.1). See [Conditional Create using "If-None-Exist"](http://build.fhir.org/http.html#2.1.0.11). See [Invalid "Content-Type" header](http://build.fhir.org/http.html#2.1.0.13.1) for negative testing. - etc.
min:
  v: 0
max:
  v: *
base:
  path:
    v: TestScript.setup.action.operation.requestHeader
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: BackboneElement
    l: BackboneElement
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children or both
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element

id:
  v: TestScript.setup.action.operation.requestHeader.id
path:
  v: TestScript.setup.action.operation.requestHeader.id
representation:
  v: xmlAttr
short:
  v: Unique id for inter-element referencing
definition:
  v: Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Element.id
  min:
    v: 0
  max:
    v: 1
type:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
      l: structuredefinition-fhir-type
    value: Url
      v: id
      l: id
  code:
    v: http://hl7.org/fhirpath/System.String
    l: System.String
condition:
  v: ele-1
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.setup.action.operation.requestHeader.extension
path:
  v: TestScript.setup.action.operation.requestHeader.extension
slicing:
  discriminator:
    type:
      v: value
    path:
      v: url
  description:
    v: Extensions are always sliced by (at least) url
  rules:
    v: open
short:
  v: Additional content defined by implementations
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
alias:
  v: extensions
alias:
  v: user content
min:
  v: 0
max:
  v: *
base:
  path:
    v: Element.extension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.setup.action.operation.requestHeader.modifierExtension
path:
  v: TestScript.setup.action.operation.requestHeader.modifierExtension
short:
  v: Extensions that cannot be ignored even if unrecognized
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions. Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
requirements:
  v: Modifier extensions allow for extensions that *cannot* be safely ignored to be clearly distinguished from the vast majority of extensions which can be safely ignored. This promotes interoperability by eliminating the need for implementers to prohibit the presence of extensions. For further information, see the [definition of modifier extensions](http://build.fhir.org/extensibility.html#modifierExtension).
alias:
  v: extensions
alias:
  v: user content
alias:
  v: modifiers
min:
  v: 0
max:
  v: *
base:
  path:
    v: BackboneElement.modifierExtension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: true
is modifier reason:
  v: Modifier extensions are expected to modify the meaning or interpretation of the element that contains them
is summary:
  v: true
mapping:
  identity:
    v: rim
  map:
    v: N/A

id:
  v: TestScript.setup.action.operation.requestHeader.field
path:
  v: TestScript.setup.action.operation.requestHeader.field
short:
  v: HTTP header field name
definition:
  v: The HTTP header field e.g. "Accept".
comment:
  v: If header element is specified, then field is required.
min:
  v: 1
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.operation.requestHeader.field
  min:
    v: 1
  max:
    v: 1
type:
  code:
    v: string
    l: string

id:
  v: TestScript.setup.action.operation.requestHeader.value
path:
  v: TestScript.setup.action.operation.requestHeader.value
short:
  v: HTTP headerfield value
definition:
  v: The value of the header e.g. "application/fhir+xml".
comment:
  v: If header element is specified, then value is required. No conversions will be done by the test engine e.g. "xml" to "application/fhir+xml". The values will be set in HTTP headers "as-is". Test engines do have to look for placeholders (${}) and replace the variable placeholders with the variable values at runtime before sending the request.
min:
  v: 1
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.operation.requestHeader.value
  min:
    v: 1
  max:
    v: 1
type:
  code:
    v: string
    l: string

id:
  v: TestScript.setup.action.operation.requestId
path:
  v: TestScript.setup.action.operation.requestId
short:
  v: Fixture Id of mapped request
definition:
  v: The fixture id (maybe new) to map to the request.
comment:
  v: If a requestId is supplied, then the resulting request (both headers and body) is mapped to the fixture ID (which may be entirely new and previously undeclared) designated by "requestId". If requestId is not specified, it is the test engine's responsibility to store the request and use it as the requestId in subsequent assertions when assertion path and/or headerField is specified, direction is equal to request, and the requestId in not specified.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.operation.requestId
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: id
    l: id

id:
  v: TestScript.setup.action.operation.responseId
path:
  v: TestScript.setup.action.operation.responseId
short:
  v: Fixture Id of mapped response
definition:
  v: The fixture id (maybe new) to map to the response.
comment:
  v: If a responseId is supplied, and the server responds, then the resulting response (both headers and body) is mapped to the fixture ID (which may be entirely new and previously undeclared) designated by "responseId". If responseId is not specified, it is the test engine's responsibility to store the response and use it as the responseId in subsequent assertions when assertion path and/or headerField is specified and the responseId is not specified.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.operation.responseId
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: id
    l: id

id:
  v: TestScript.setup.action.operation.sourceId
path:
  v: TestScript.setup.action.operation.sourceId
short:
  v: Fixture Id of body for PUT and POST requests
definition:
  v: The id of the fixture used as the body of a PUT or POST request.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.operation.sourceId
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: id
    l: id
condition:
  v: tst-4

id:
  v: TestScript.setup.action.operation.targetId
path:
  v: TestScript.setup.action.operation.targetId
short:
  v: Id of fixture used for extracting the [id], [type], and [vid] for GET requests
definition:
  v: Id of fixture used for extracting the [id], [type], and [vid] for GET requests.
comment:
  v: If "url" element is specified, then "targetId", "params", and "resource" elements will be ignored as "url" element will have everything needed for constructing the request url. If "params" element is specified, then "targetId" element is ignored. For FHIR operations that require a resource (e.g. "read" and "vread" operations), the "resource" element must be specified when "params" element is specified. If "url" and "params" elements are absent, then the request url will be constructed from "targetId" fixture if present. For "read" operation, the resource and id values will be extracted from "targetId" fixture and used to construct the url. For "vread" and "history" operations, the versionId value will also be used.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.operation.targetId
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: id
    l: id
condition:
  v: tst-4

id:
  v: TestScript.setup.action.operation.url
path:
  v: TestScript.setup.action.operation.url
short:
  v: Request URL
definition:
  v: Complete request URL.
comment:
  v: Used to set the request URL explicitly. If "url" element is defined, then "targetId", "resource", and "params" elements will be ignored. Test engines would use whatever is specified in "url" without tampering with the string (beyond encoding the URL for HTTP). Test engines do have to look for placeholders (${}) and replace the variable placeholders with the variable values at runtime before sending the request.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.operation.url
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string
condition:
  v: tst-4

id:
  v: TestScript.setup.action.assert
path:
  v: TestScript.setup.action.assert
short:
  v: The assertion to perform
definition:
  v: Evaluates the results of previous operations to determine if the server under test behaves appropriately.
comment:
  v: In order to evaluate an assertion, the request, response, and results of the most recently executed operation must always be maintained by the test engine.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.assert
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: BackboneElement
    l: BackboneElement
condition:
  v: tst-3
constraint:
  key:
    v: tst-5
  severity:
    v: error
  human:
    v: Setup action assert SHALL contain either compareToSourceId and compareToSourceExpression, compareToSourceId and compareToSourcePath or neither.
  expression:
    v: compareToSourceId.empty() xor (compareToSourceExpression.exists() or compareToSourcePath.exists())
  source:
    v: http://hl7.org/fhir/StructureDefinition/TestScript
    l: TestScript
constraint:
  key:
    v: tst-6
  severity:
    v: error
  human:
    v: Setup action assert response and responseCode SHALL be empty when direction equals request
  expression:
    v: (response.empty() and responseCode.empty() and direction = 'request') or direction.empty() or direction = 'response'
  source:
    v: http://hl7.org/fhir/StructureDefinition/TestScript
    l: TestScript
constraint:
  key:
    v: tst-7
  severity:
    v: error
  human:
    v: A setup action assert SHALL define a singular assertion function and prevent overlapping assertion functionality.
  expression:
    v: extension.exists() or (contentType.count() + expression.count() + headerField.count() + minimumId.count() + navigationLinks.count() + path.count() + requestMethod.count() + requestURL.count() + resource.count() + responseCode.count() + response.count() + validateProfileId.count() <= 1)
  source:
    v: http://hl7.org/fhir/StructureDefinition/TestScript
    l: TestScript
constraint:
  key:
    v: tst-8
  severity:
    v: error
  human:
    v: A setup action assert SHALL not allow the use of operator and value with minimumId, navigationLinks or validateProfileId.
  expression:
    v: extension.exists() or (minimumId.count() + navigationLinks.count() + validateProfileId.count() = 0) or (minimumId.count() + navigationLinks.count() + validateProfileId.count() = 1 and operator.count() + value.count() = 0)
  source:
    v: http://hl7.org/fhir/StructureDefinition/TestScript
    l: TestScript
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children or both
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element

id:
  v: TestScript.setup.action.assert.id
path:
  v: TestScript.setup.action.assert.id
representation:
  v: xmlAttr
short:
  v: Unique id for inter-element referencing
definition:
  v: Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Element.id
  min:
    v: 0
  max:
    v: 1
type:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
      l: structuredefinition-fhir-type
    value: Url
      v: id
      l: id
  code:
    v: http://hl7.org/fhirpath/System.String
    l: System.String
condition:
  v: ele-1
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.setup.action.assert.extension
path:
  v: TestScript.setup.action.assert.extension
slicing:
  discriminator:
    type:
      v: value
    path:
      v: url
  description:
    v: Extensions are always sliced by (at least) url
  rules:
    v: open
short:
  v: Additional content defined by implementations
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
alias:
  v: extensions
alias:
  v: user content
min:
  v: 0
max:
  v: *
base:
  path:
    v: Element.extension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.setup.action.assert.modifierExtension
path:
  v: TestScript.setup.action.assert.modifierExtension
short:
  v: Extensions that cannot be ignored even if unrecognized
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions. Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
requirements:
  v: Modifier extensions allow for extensions that *cannot* be safely ignored to be clearly distinguished from the vast majority of extensions which can be safely ignored. This promotes interoperability by eliminating the need for implementers to prohibit the presence of extensions. For further information, see the [definition of modifier extensions](http://build.fhir.org/extensibility.html#modifierExtension).
alias:
  v: extensions
alias:
  v: user content
alias:
  v: modifiers
min:
  v: 0
max:
  v: *
base:
  path:
    v: BackboneElement.modifierExtension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: true
is modifier reason:
  v: Modifier extensions are expected to modify the meaning or interpretation of the element that contains them
is summary:
  v: true
mapping:
  identity:
    v: rim
  map:
    v: N/A

id:
  v: TestScript.setup.action.assert.label
path:
  v: TestScript.setup.action.assert.label
short:
  v: Tracking/logging assertion label
definition:
  v: The label would be used for tracking/logging purposes by test engines.
comment:
  v: This has no impact on the verification itself.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.assert.label
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string

id:
  v: TestScript.setup.action.assert.key
path:
  v: TestScript.setup.action.assert.key
short:
  v: Key that identifies this assert
definition:
  v: The key that identifies this assert (unique within this TestScript).
comment:
  v: This may be referenced by downstream assert.evaluateBasedOn for conditional evaluation by the test engine.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.assert.key
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: id
    l: id

id:
  v: TestScript.setup.action.assert.evaluateBasedOn
path:
  v: TestScript.setup.action.assert.evaluateBasedOn
short:
  v: Zero or more assert.key references
definition:
  v: A list of zero or more assert.key references to conditionally determine if this assert will be evaluated.
comment:
  v: This may reference upstream assert.key value(s) for conditional evaluation of this assert by the test engine.
min:
  v: 0
max:
  v: *
base:
  path:
    v: TestScript.setup.action.assert.evaluateBasedOn
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: id
    l: id

id:
  v: TestScript.setup.action.assert.description
path:
  v: TestScript.setup.action.assert.description
short:
  v: Tracking/reporting assertion description
definition:
  v: The description would be used by test engines for tracking and reporting purposes.
comment:
  v: This has no impact on the verification itself.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.assert.description
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string

id:
  v: TestScript.setup.action.assert.direction
path:
  v: TestScript.setup.action.assert.direction
short:
  v: response | request
definition:
  v: The direction to use for the assertion.
comment:
  v: If the direction is specified as "response" (the default), then the processing of this assert is against the received response message. If the direction is specified as "request", then the processing of this assert is against the sent request message.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.assert.direction
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: code
    l: code
condition:
  v: tst-6
binding:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
      l: elementdefinition-bindingName
    value: String
      v: AssertionDirectionType
  extension:
    url:
      v: http://hl7.org/fhir/tools/StructureDefinition/binding-definition
      l: binding-definition
    value: Markdown
      v: The type of direction to use for assertion.
  strength:
    v: required
  description:
    v: The direction to use for assertions.
  value set:
    v: http://hl7.org/fhir/ValueSet/assert-direction-codes
    l: assert-direction-codes

id:
  v: TestScript.setup.action.assert.compareToSourceId
path:
  v: TestScript.setup.action.assert.compareToSourceId
short:
  v: Id of the source fixture to be evaluated
definition:
  v: Id of the source fixture used as the contents to be evaluated by either the "assert.compareToSourceExpression" or "assert.compareToSourcePath" definition.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.assert.compareToSourceId
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string
condition:
  v: tst-5

id:
  v: TestScript.setup.action.assert.compareToSourceExpression
path:
  v: TestScript.setup.action.assert.compareToSourceExpression
short:
  v: The expression to evaluate against the source fixture
definition:
  v: The expression for a specific value to evaluate against the source fixture. When compareToSourceId is defined, either compareToSourceExpression or compareToSourcePath must be defined, but not both.
comment:
  v: The expression to be evaluated against the expected fixture to compare to. Ignored if "assert.value" is used. The evaluation will be done before the assertion is evaluated.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.assert.compareToSourceExpression
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: Expression
    l: Expression
condition:
  v: tst-5

id:
  v: TestScript.setup.action.assert.compareToSourcePath
extension:
  url:
    v: http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status
    l: structuredefinition-standards-status
  value: Code
    v: deprecated
path:
  v: TestScript.setup.action.assert.compareToSourcePath
short:
  v: XPath or JSONPath expression to evaluate against the source fixture
definition:
  v: XPath or JSONPath expression to evaluate against the source fixture. When compareToSourceId is defined, either compareToSourceExpression or compareToSourcePath must be defined, but not both.
comment:
  v: The XPath or JSONPath expression to be evaluated against the expected fixture to compare to. Ignored if "assert.value" is used. The evaluation will be done before the assertion is evaluated.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.assert.compareToSourcePath
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string
condition:
  v: tst-5

id:
  v: TestScript.setup.action.assert.contentType
path:
  v: TestScript.setup.action.assert.contentType
short:
  v: Mime type to compare against the 'Content-Type' header
definition:
  v: The mime-type contents to compare against the request or response message 'Content-Type' header.
comment:
  v: If this is specified, then test engine shall confirm that the content-type of the last operation's headers is set to this value. If "assert.sourceId" element is specified, then the evaluation will be done against the headers mapped to that sourceId (and not the last operation's headers). If you'd like to have more control over the string, then use 'assert.headerField' instead.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.assert.contentType
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: code
    l: code
example:
  label:
    v: General
  value: Code
    v: application/fhir+xml
condition:
  v: tst-7
binding:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
      l: elementdefinition-bindingName
    value: String
      v: SupplementedMimeType
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-isCommonBinding
      l: elementdefinition-isCommonBinding
    value: Boolean
      v: true
  strength:
    v: required
  description:
    v: The mime type of an attachment. Any valid mime type is allowed (BCP 13; RFCs 2045, 2046, 2047, 4288, 4289 and 2049), and also `json`, `xml`, and `ttl`.
  value set:
    v: http://hl7.org/fhir/ValueSet/supplemented-mimetypes
    l: supplemented-mimetypes
  additional:
    purpose:
      v: starter
    value set:
      v: http://hl7.org/fhir/ValueSet/capability-format-type
      l: capability-format-type

id:
  v: TestScript.setup.action.assert.defaultManualCompletion
path:
  v: TestScript.setup.action.assert.defaultManualCompletion
short:
  v: fail | pass | skip | stop
definition:
  v: The default manual completion outcome applied to this assertion.
comment:
  v: Manual completion is used to pause the test engine execution and evaluation allowing an external review of the defined assert condition. The defaultManualCompletion defines the default manual completion outcome applied if one of the enumerated values is not applied.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.assert.defaultManualCompletion
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: code
    l: code
meaning when missing:
  v: If defaultManualCompletion is not specified, then the default manual completion outcome will be 'skip'.
binding:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
      l: elementdefinition-bindingName
    value: String
      v: AssertionManualCompletionType
  extension:
    url:
      v: http://hl7.org/fhir/tools/StructureDefinition/binding-definition
      l: binding-definition
    value: Markdown
      v: The type of operator to use for assertion.
  strength:
    v: required
  description:
    v: The default type of manual completion to use for assertion.
  value set:
    v: http://hl7.org/fhir/ValueSet/assert-manual-completion-codes
    l: assert-manual-completion-codes

id:
  v: TestScript.setup.action.assert.expression
path:
  v: TestScript.setup.action.assert.expression
short:
  v: The expression to be evaluated
definition:
  v: The expression to be evaluated against the request or response message contents - HTTP headers and payload.
comment:
  v: If both "expression" and a "fixtureId" are specified, then the expression will be evaluated against the request or response body mapped to the fixtureId. If "expression" is specified and a "fixtureId" is not, then the expression will be evaluated against the response body of the last operation. Test engines are to store the request and response body and headers of the last operation at all times for subsequent assertions. The expression can be evaluated as either a path to a specific value or as a boolean expression against the given sourceId. When the expression evaluates to a boolean, the assert.value element is not used. See [Testing FHIR Use Expressions](http://hl7.org/fhir/R5/testing.html#expressions). A test engine is expected to minimally support the expression languages: text/fhirpath, application/xml and application/json.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.assert.expression
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: Expression
    l: Expression
condition:
  v: tst-7

id:
  v: TestScript.setup.action.assert.headerField
path:
  v: TestScript.setup.action.assert.headerField
short:
  v: HTTP header field name
definition:
  v: The HTTP header field name e.g. 'Location'.
comment:
  v: If "headerField" is specified then "value" must be specified. If "sourceId" is not specified, then "headerField" will be evaluated against the last operation's response headers. Test engines are to keep track of the last operation's response body and response headers.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.assert.headerField
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string
condition:
  v: tst-7

id:
  v: TestScript.setup.action.assert.minimumId
path:
  v: TestScript.setup.action.assert.minimumId
short:
  v: Fixture Id of minimum content resource
definition:
  v: The ID of a fixture. Asserts that the response contains at a minimum the fixture specified by minimumId.
comment:
  v: Asserts that the response contains all the element/content in another fixture pointed to by minimumId. This can be a statically defined fixture or one that is dynamically set via responseId. See [Testing FHIR Use minimumId](http://hl7.org/fhir/R5/testing.html#minimumId) for a more complete description of the test engine's comparison logic.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.assert.minimumId
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string
condition:
  v: tst-7
condition:
  v: tst-8

id:
  v: TestScript.setup.action.assert.navigationLinks
path:
  v: TestScript.setup.action.assert.navigationLinks
short:
  v: Perform validation on navigation links?
definition:
  v: Whether or not the test execution performs validation on the bundle navigation links.
comment:
  v: Asserts that the Bundle contains first, last, and next links.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.assert.navigationLinks
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: boolean
    l: boolean
condition:
  v: tst-7
condition:
  v: tst-8

id:
  v: TestScript.setup.action.assert.operator
path:
  v: TestScript.setup.action.assert.operator
short:
  v: equals | notEquals | in | notIn | greaterThan | lessThan | empty | notEmpty | contains | notContains | eval | manualEval
definition:
  v: The operator type defines the conditional behavior of the assert.
comment:
  v: Operators are useful for both positive and negative testing. If operator is not specified, then the default conditional behavior is implemented as defined in [Testing FHIR Assertions](http://hl7.org/fhir/R5/testing.html#assertion-table).
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.assert.operator
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: code
    l: code
meaning when missing:
  v: If operator is not specified, then the default conditional behavior is implemented as defined in the Testing FHIR page Assertions table - see Comments.
condition:
  v: tst-8
binding:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
      l: elementdefinition-bindingName
    value: String
      v: AssertionOperatorType
  extension:
    url:
      v: http://hl7.org/fhir/tools/StructureDefinition/binding-definition
      l: binding-definition
    value: Markdown
      v: The type of operator to use for assertion.
  strength:
    v: required
  description:
    v: The type of operator to use for assertions.
  value set:
    v: http://hl7.org/fhir/ValueSet/assert-operator-codes
    l: assert-operator-codes

id:
  v: TestScript.setup.action.assert.path
extension:
  url:
    v: http://hl7.org/fhir/StructureDefinition/structuredefinition-standards-status
    l: structuredefinition-standards-status
  value: Code
    v: deprecated
path:
  v: TestScript.setup.action.assert.path
short:
  v: XPath or JSONPath expression
definition:
  v: The XPath or JSONPath expression to be evaluated against the fixture representing the response received from server.
comment:
  v: If both "path" and a "fixtureId" are specified, then the path will be evaluated against the request or response body mapped to the fixtureId. If "path" is specified and a "fixtureId" is not, then the path will be evaluated against the response body of the last operation. Test engines are to store the request and response body and headers of the last operation at all times for subsequent assertions.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.assert.path
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string
condition:
  v: tst-7

id:
  v: TestScript.setup.action.assert.requestMethod
path:
  v: TestScript.setup.action.assert.requestMethod
short:
  v: delete | get | options | patch | post | put | head
definition:
  v: The request method or HTTP operation code to compare against that used by the client system under test.
comment:
  v: If "requestMethod" is specified then it will be used in place of "value". The "requestMethod" will evaluate against the last operation's request HTTP operation.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.assert.requestMethod
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: code
    l: code
condition:
  v: tst-7
binding:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
      l: elementdefinition-bindingName
    value: String
      v: TestScriptRequestMethodCode
  strength:
    v: required
  description:
    v: The allowable request method or HTTP operation codes.
  value set:
    v: http://hl7.org/fhir/ValueSet/http-operations
    l: http-operations

id:
  v: TestScript.setup.action.assert.requestURL
path:
  v: TestScript.setup.action.assert.requestURL
short:
  v: Request URL comparison value
definition:
  v: The value to use in a comparison against the request URL path string.
comment:
  v: If "requestURL" is specified then it will be used in place of "value". The "requestURL" will evaluate against the last operation's full request URL path string.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.assert.requestURL
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string
condition:
  v: tst-7

id:
  v: TestScript.setup.action.assert.resource
path:
  v: TestScript.setup.action.assert.resource
short:
  v: Resource type
definition:
  v: The type of the resource. See the [resource list](http://hl7.org/fhir/R5/resourcelist.html).
comment:
  v: This will be expected resource type in response body e.g. in read, vread, search, etc. See the [Resource List](http://hl7.org/fhir/R5/resourcelist.html) for complete list of resource types; e.g. <assert > <resourceType value="Patient" </assert>.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.assert.resource
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: uri
    l: uri
condition:
  v: tst-7
binding:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
      l: elementdefinition-bindingName
    value: String
      v: FHIRConcreteType
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-isCommonBinding
      l: elementdefinition-isCommonBinding
    value: Boolean
      v: true
  strength:
    v: extensible
  description:
    v: A list of all the concrete types defined in this version of the FHIR specification - Data Types and Resource Types.
  value set:
    v: http://hl7.org/fhir/ValueSet/concrete-fhir-types
    l: concrete-fhir-types

id:
  v: TestScript.setup.action.assert.response
path:
  v: TestScript.setup.action.assert.response
short:
  v: continue | switchingProtocols | okay | created | accepted | nonAuthoritativeInformation | noContent | resetContent | partialContent | multipleChoices | movedPermanently | found | seeOther | notModified | useProxy | temporaryRedirect | permanentRedirect | badRequest | unauthorized | paymentRequired | forbidden | notFound | methodNotAllowed | notAcceptable | proxyAuthenticationRequired | requestTimeout | conflict | gone | lengthRequired | preconditionFailed | contentTooLarge | uriTooLong | unsupportedMediaType | rangeNotSatisfiable | expectationFailed | misdirectedRequest | unprocessableContent | upgradeRequired | internalServerError | notImplemented | badGateway | serviceUnavailable | gatewayTimeout | httpVersionNotSupported
definition:
  v: continue | switchingProtocols | okay | created | accepted | nonAuthoritativeInformation | noContent | resetContent | partialContent | multipleChoices | movedPermanently | found | seeOther | notModified | useProxy | temporaryRedirect | permanentRedirect | badRequest | unauthorized | paymentRequired | forbidden | notFound | methodNotAllowed | notAcceptable | proxyAuthenticationRequired | requestTimeout | conflict | gone | lengthRequired | preconditionFailed | contentTooLarge | uriTooLong | unsupportedMediaType | rangeNotSatisfiable | expectationFailed | misdirectedRequest | unprocessableContent | upgradeRequired | internalServerError | notImplemented | badGateway | serviceUnavailable | gatewayTimeout | httpVersionNotSupported.
comment:
  v: This is a shorter way of achieving similar verifications via "assert.responseCode". If you need more control, then use "assert.responseCode" e.g. <assert> <contentType value="json" /> <response value="okay"/> </assert>.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.assert.response
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: code
    l: code
condition:
  v: tst-6
condition:
  v: tst-7
binding:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
      l: elementdefinition-bindingName
    value: String
      v: AssertionResponseTypes
  extension:
    url:
      v: http://hl7.org/fhir/tools/StructureDefinition/binding-definition
      l: binding-definition
    value: Markdown
      v: The type of response code to use for assertion.
  strength:
    v: required
  description:
    v: The response code to expect in the response.
  value set:
    v: http://hl7.org/fhir/ValueSet/assert-response-code-types
    l: assert-response-code-types

id:
  v: TestScript.setup.action.assert.responseCode
path:
  v: TestScript.setup.action.assert.responseCode
short:
  v: HTTP response code to test
definition:
  v: The value of the HTTP response code to be tested.
comment:
  v: To be used with "operator" attribute value. Asserts that the response code equals this value if "operator" is not specified. If the operator is "in" or "notIn" then the responseCode would be a comma-separated list of values e.g. "200,201". Otherwise, it's expected to be a numeric value. If "fixture" is not specified, then the "responseBodyId" value of the last operation is assumed.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.assert.responseCode
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string
condition:
  v: tst-6
condition:
  v: tst-7

id:
  v: TestScript.setup.action.assert.sourceId
path:
  v: TestScript.setup.action.assert.sourceId
short:
  v: Fixture Id of source expression or headerField
definition:
  v: Fixture to evaluate the XPath/JSONPath expression or the headerField against.
comment:
  v: This can be a statically defined fixture (at the top of the testscript) or a dynamically set fixture created by responseId of the action.operation element.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.assert.sourceId
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: id
    l: id

id:
  v: TestScript.setup.action.assert.stopTestOnFail
path:
  v: TestScript.setup.action.assert.stopTestOnFail
short:
  v: If this assert fails, will the current test execution stop?
definition:
  v: Whether or not the current test execution will stop on failure for this assert.
comment:
  v: If this element is specified and it is true, then assertion failures should not stop the current test execution from proceeding.
min:
  v: 1
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.assert.stopTestOnFail
  min:
    v: 1
  max:
    v: 1
type:
  code:
    v: boolean
    l: boolean

id:
  v: TestScript.setup.action.assert.validateProfileId
path:
  v: TestScript.setup.action.assert.validateProfileId
short:
  v: Profile Id of validation profile reference
definition:
  v: The ID of the Profile to validate against.
comment:
  v: The ID of a Profile fixture. Asserts that the response is valid according to the Profile specified by validateProfileId.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.assert.validateProfileId
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: id
    l: id
condition:
  v: tst-7
condition:
  v: tst-8

id:
  v: TestScript.setup.action.assert.value
path:
  v: TestScript.setup.action.assert.value
short:
  v: The value to compare to
definition:
  v: The value to compare to.
comment:
  v: The string-representation of a number, string, or boolean that is expected. Test engines do have to look for placeholders (${}) and replace the variable placeholders with the variable values at runtime before comparing this value to the actual value.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.assert.value
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string
condition:
  v: tst-8

id:
  v: TestScript.setup.action.assert.warningOnly
path:
  v: TestScript.setup.action.assert.warningOnly
short:
  v: Will this assert produce a warning only on error?
definition:
  v: Whether or not the test execution will produce a warning only on error for this assert.
comment:
  v: If this element is specified and it is true, then assertion failures can be logged by test engine but should not stop the test script execution from proceeding. There are likely cases where the spec is not clear on what should happen. If the spec says something is optional (maybe a response header for example), but a server doesn’t do it, we could choose to issue a warning.
min:
  v: 1
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.assert.warningOnly
  min:
    v: 1
  max:
    v: 1
type:
  code:
    v: boolean
    l: boolean

id:
  v: TestScript.setup.action.assert.requirement
path:
  v: TestScript.setup.action.assert.requirement
short:
  v: Links or references to the testing requirements
definition:
  v: Links or references providing traceability to the testing requirements for this assert.
comment:
  v: TestScript and TestReport instances are typically (and expected to be) based on known, defined test requirements and documentation. These links provide traceability from the executable/executed TestScript and TestReport tests to these requirements.
min:
  v: 0
max:
  v: *
base:
  path:
    v: TestScript.setup.action.assert.requirement
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: BackboneElement
    l: BackboneElement
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children or both
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element

id:
  v: TestScript.setup.action.assert.requirement.id
path:
  v: TestScript.setup.action.assert.requirement.id
representation:
  v: xmlAttr
short:
  v: Unique id for inter-element referencing
definition:
  v: Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Element.id
  min:
    v: 0
  max:
    v: 1
type:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
      l: structuredefinition-fhir-type
    value: Url
      v: id
      l: id
  code:
    v: http://hl7.org/fhirpath/System.String
    l: System.String
condition:
  v: ele-1
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.setup.action.assert.requirement.extension
path:
  v: TestScript.setup.action.assert.requirement.extension
slicing:
  discriminator:
    type:
      v: value
    path:
      v: url
  description:
    v: Extensions are always sliced by (at least) url
  rules:
    v: open
short:
  v: Additional content defined by implementations
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
alias:
  v: extensions
alias:
  v: user content
min:
  v: 0
max:
  v: *
base:
  path:
    v: Element.extension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.setup.action.assert.requirement.modifierExtension
path:
  v: TestScript.setup.action.assert.requirement.modifierExtension
short:
  v: Extensions that cannot be ignored even if unrecognized
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions. Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
requirements:
  v: Modifier extensions allow for extensions that *cannot* be safely ignored to be clearly distinguished from the vast majority of extensions which can be safely ignored. This promotes interoperability by eliminating the need for implementers to prohibit the presence of extensions. For further information, see the [definition of modifier extensions](http://build.fhir.org/extensibility.html#modifierExtension).
alias:
  v: extensions
alias:
  v: user content
alias:
  v: modifiers
min:
  v: 0
max:
  v: *
base:
  path:
    v: BackboneElement.modifierExtension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: true
is modifier reason:
  v: Modifier extensions are expected to modify the meaning or interpretation of the element that contains them
is summary:
  v: true
mapping:
  identity:
    v: rim
  map:
    v: N/A

id:
  v: TestScript.setup.action.assert.requirement.reference
path:
  v: TestScript.setup.action.assert.requirement.reference
short:
  v: Canonical reference to the Requirements instance
definition:
  v: Canonical reference providing traceability to the testing requirement for this assert.
min:
  v: 1
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.assert.requirement.reference
  min:
    v: 1
  max:
    v: 1
type:
  code:
    v: canonical
    l: canonical
  target profile:
    v: http://hl7.org/fhir/StructureDefinition/Requirements
    l: Requirements

id:
  v: TestScript.setup.action.assert.requirement.key
path:
  v: TestScript.setup.action.assert.requirement.key
short:
  v: Requirements statement key identifier
definition:
  v: Requirements.statement.key that identifies the statement that this assert satisfies.
min:
  v: 1
max:
  v: 1
base:
  path:
    v: TestScript.setup.action.assert.requirement.key
  min:
    v: 1
  max:
    v: 1
type:
  code:
    v: id
    l: id

id:
  v: TestScript.test
path:
  v: TestScript.test
short:
  v: A test in this script
definition:
  v: A test in this script.
min:
  v: 0
max:
  v: *
base:
  path:
    v: TestScript.test
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: BackboneElement
    l: BackboneElement
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children or both
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element

id:
  v: TestScript.test.id
path:
  v: TestScript.test.id
representation:
  v: xmlAttr
short:
  v: Unique id for inter-element referencing
definition:
  v: Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Element.id
  min:
    v: 0
  max:
    v: 1
type:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
      l: structuredefinition-fhir-type
    value: Url
      v: id
      l: id
  code:
    v: http://hl7.org/fhirpath/System.String
    l: System.String
condition:
  v: ele-1
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.test.extension
path:
  v: TestScript.test.extension
slicing:
  discriminator:
    type:
      v: value
    path:
      v: url
  description:
    v: Extensions are always sliced by (at least) url
  rules:
    v: open
short:
  v: Additional content defined by implementations
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
alias:
  v: extensions
alias:
  v: user content
min:
  v: 0
max:
  v: *
base:
  path:
    v: Element.extension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.test.modifierExtension
path:
  v: TestScript.test.modifierExtension
short:
  v: Extensions that cannot be ignored even if unrecognized
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions. Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
requirements:
  v: Modifier extensions allow for extensions that *cannot* be safely ignored to be clearly distinguished from the vast majority of extensions which can be safely ignored. This promotes interoperability by eliminating the need for implementers to prohibit the presence of extensions. For further information, see the [definition of modifier extensions](http://build.fhir.org/extensibility.html#modifierExtension).
alias:
  v: extensions
alias:
  v: user content
alias:
  v: modifiers
min:
  v: 0
max:
  v: *
base:
  path:
    v: BackboneElement.modifierExtension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: true
is modifier reason:
  v: Modifier extensions are expected to modify the meaning or interpretation of the element that contains them
is summary:
  v: true
mapping:
  identity:
    v: rim
  map:
    v: N/A

id:
  v: TestScript.test.name
path:
  v: TestScript.test.name
short:
  v: Tracking/logging name of this test
definition:
  v: The name of this test used for tracking/logging purposes by test engines.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.test.name
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string

id:
  v: TestScript.test.description
path:
  v: TestScript.test.description
short:
  v: Tracking/reporting short description of the test
definition:
  v: A short description of the test used by test engines for tracking and reporting purposes.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.test.description
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string

id:
  v: TestScript.test.action
extension:
  url:
    v: http://hl7.org/fhir/StructureDefinition/structuredefinition-explicit-type-name
    l: structuredefinition-explicit-type-name
  value: String
    v: TestAction
path:
  v: TestScript.test.action
short:
  v: A test operation or assert to perform
definition:
  v: Action would contain either an operation or an assertion.
comment:
  v: An action should contain either an operation or an assertion but not both. It can contain any number of variables.
min:
  v: 0
max:
  v: *
base:
  path:
    v: TestScript.test.action
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: BackboneElement
    l: BackboneElement
constraint:
  key:
    v: tst-9
  severity:
    v: error
  human:
    v: Test action SHALL contain only one of either a common or an operation or an assert.
  expression:
    v: common.exists() xor operation.exists() xor assert.exists()
  source:
    v: http://hl7.org/fhir/StructureDefinition/TestScript
    l: TestScript
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children or both
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element

id:
  v: TestScript.test.action.id
path:
  v: TestScript.test.action.id
representation:
  v: xmlAttr
short:
  v: Unique id for inter-element referencing
definition:
  v: Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Element.id
  min:
    v: 0
  max:
    v: 1
type:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
      l: structuredefinition-fhir-type
    value: Url
      v: id
      l: id
  code:
    v: http://hl7.org/fhirpath/System.String
    l: System.String
condition:
  v: ele-1
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.test.action.extension
path:
  v: TestScript.test.action.extension
slicing:
  discriminator:
    type:
      v: value
    path:
      v: url
  description:
    v: Extensions are always sliced by (at least) url
  rules:
    v: open
short:
  v: Additional content defined by implementations
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
alias:
  v: extensions
alias:
  v: user content
min:
  v: 0
max:
  v: *
base:
  path:
    v: Element.extension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.test.action.modifierExtension
path:
  v: TestScript.test.action.modifierExtension
short:
  v: Extensions that cannot be ignored even if unrecognized
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions. Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
requirements:
  v: Modifier extensions allow for extensions that *cannot* be safely ignored to be clearly distinguished from the vast majority of extensions which can be safely ignored. This promotes interoperability by eliminating the need for implementers to prohibit the presence of extensions. For further information, see the [definition of modifier extensions](http://build.fhir.org/extensibility.html#modifierExtension).
alias:
  v: extensions
alias:
  v: user content
alias:
  v: modifiers
min:
  v: 0
max:
  v: *
base:
  path:
    v: BackboneElement.modifierExtension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: true
is modifier reason:
  v: Modifier extensions are expected to modify the meaning or interpretation of the element that contains them
is summary:
  v: true
mapping:
  identity:
    v: rim
  map:
    v: N/A

id:
  v: TestScript.test.action.common
path:
  v: TestScript.test.action.common
short:
  v: Links or references to common collection(s) of actions
definition:
  v: Links or references to common collection(s) of actions in this or an external TestScript instance.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.test.action.common
  min:
    v: 0
  max:
    v: 1
content reference:
  v: http://hl7.org/fhir/StructureDefinition/TestScript#TestScript.setup.action.common
  l: TestScript.setup.action.common
type:
  code:
    v: BackboneElement
    l: BackboneElement

id:
  v: TestScript.test.action.operation
path:
  v: TestScript.test.action.operation
short:
  v: The setup operation to perform
definition:
  v: An operation would involve a REST request to a server.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.test.action.operation
  min:
    v: 0
  max:
    v: 1
content reference:
  v: http://hl7.org/fhir/StructureDefinition/TestScript#TestScript.setup.action.operation
  l: TestScript.setup.action.operation
constraint:
  key:
    v: tst-10
  severity:
    v: error
  human:
    v: Test operation SHALL contain either sourceId or targetId or params or url.
  expression:
    v: sourceId.exists() or (targetId.count() + url.count() + params.count() = 1) or (type.code in ('capabilities' | 'search' | 'transaction' | 'history'))
  source:
    v: http://hl7.org/fhir/StructureDefinition/TestScript
    l: TestScript

id:
  v: TestScript.test.action.assert
path:
  v: TestScript.test.action.assert
short:
  v: The setup assertion to perform
definition:
  v: Evaluates the results of previous operations to determine if the server under test behaves appropriately.
comment:
  v: In order to evaluate an assertion, the request, response, and results of the most recently executed operation must always be maintained by the test engine.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.test.action.assert
  min:
    v: 0
  max:
    v: 1
content reference:
  v: http://hl7.org/fhir/StructureDefinition/TestScript#TestScript.setup.action.assert
  l: TestScript.setup.action.assert
constraint:
  key:
    v: tst-11
  severity:
    v: error
  human:
    v: Test action assert SHALL contain either compareToSourceId and compareToSourceExpression, compareToSourceId and compareToSourcePath or neither.
  expression:
    v: compareToSourceId.empty() xor (compareToSourceExpression.exists() or compareToSourcePath.exists())
  source:
    v: http://hl7.org/fhir/StructureDefinition/TestScript
    l: TestScript
constraint:
  key:
    v: tst-12
  severity:
    v: error
  human:
    v: Test action assert response and response and responseCode SHALL be empty when direction equals request
  expression:
    v: (response.empty() and responseCode.empty() and direction = 'request') or direction.empty() or direction = 'response'
  source:
    v: http://hl7.org/fhir/StructureDefinition/TestScript
    l: TestScript
constraint:
  key:
    v: tst-13
  severity:
    v: error
  human:
    v: A test action assert SHALL define a singular assertion function and prevent overlapping assertion functionality.
  expression:
    v: extension.exists() or (contentType.count() + expression.count() + headerField.count() + minimumId.count() + navigationLinks.count() + path.count() + requestMethod.count() + requestURL.count() + resource.count() + responseCode.count() + response.count() + validateProfileId.count() <= 1)
  source:
    v: http://hl7.org/fhir/StructureDefinition/TestScript
    l: TestScript
constraint:
  key:
    v: tst-14
  severity:
    v: error
  human:
    v: A test action assert SHALL not allow the use of operator and value with minimumId, navigationLinks or validateProfileId.
  expression:
    v: extension.exists() or (minimumId.count() + navigationLinks.count() + validateProfileId.count() = 0) or (minimumId.count() + navigationLinks.count() + validateProfileId.count() = 1 and operator.count() + value.count() = 0)
  source:
    v: http://hl7.org/fhir/StructureDefinition/TestScript
    l: TestScript

id:
  v: TestScript.teardown
path:
  v: TestScript.teardown
short:
  v: A series of required clean up steps
definition:
  v: A series of operations required to clean up after all the tests are executed (successfully or otherwise).
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.teardown
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: BackboneElement
    l: BackboneElement
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children or both
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element

id:
  v: TestScript.teardown.id
path:
  v: TestScript.teardown.id
representation:
  v: xmlAttr
short:
  v: Unique id for inter-element referencing
definition:
  v: Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Element.id
  min:
    v: 0
  max:
    v: 1
type:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
      l: structuredefinition-fhir-type
    value: Url
      v: id
      l: id
  code:
    v: http://hl7.org/fhirpath/System.String
    l: System.String
condition:
  v: ele-1
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.teardown.extension
path:
  v: TestScript.teardown.extension
slicing:
  discriminator:
    type:
      v: value
    path:
      v: url
  description:
    v: Extensions are always sliced by (at least) url
  rules:
    v: open
short:
  v: Additional content defined by implementations
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
alias:
  v: extensions
alias:
  v: user content
min:
  v: 0
max:
  v: *
base:
  path:
    v: Element.extension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.teardown.modifierExtension
path:
  v: TestScript.teardown.modifierExtension
short:
  v: Extensions that cannot be ignored even if unrecognized
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions. Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
requirements:
  v: Modifier extensions allow for extensions that *cannot* be safely ignored to be clearly distinguished from the vast majority of extensions which can be safely ignored. This promotes interoperability by eliminating the need for implementers to prohibit the presence of extensions. For further information, see the [definition of modifier extensions](http://build.fhir.org/extensibility.html#modifierExtension).
alias:
  v: extensions
alias:
  v: user content
alias:
  v: modifiers
min:
  v: 0
max:
  v: *
base:
  path:
    v: BackboneElement.modifierExtension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: true
is modifier reason:
  v: Modifier extensions are expected to modify the meaning or interpretation of the element that contains them
is summary:
  v: true
mapping:
  identity:
    v: rim
  map:
    v: N/A

id:
  v: TestScript.teardown.action
extension:
  url:
    v: http://hl7.org/fhir/StructureDefinition/structuredefinition-explicit-type-name
    l: structuredefinition-explicit-type-name
  value: String
    v: TeardownAction
path:
  v: TestScript.teardown.action
short:
  v: One or more teardown operations to perform
definition:
  v: The teardown action will only contain an operation.
comment:
  v: An action should contain either an operation or an assertion but not both. It can contain any number of variables.
min:
  v: 1
max:
  v: *
base:
  path:
    v: TestScript.teardown.action
  min:
    v: 1
  max:
    v: *
type:
  code:
    v: BackboneElement
    l: BackboneElement
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children or both
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element

id:
  v: TestScript.teardown.action.id
path:
  v: TestScript.teardown.action.id
representation:
  v: xmlAttr
short:
  v: Unique id for inter-element referencing
definition:
  v: Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Element.id
  min:
    v: 0
  max:
    v: 1
type:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
      l: structuredefinition-fhir-type
    value: Url
      v: id
      l: id
  code:
    v: http://hl7.org/fhirpath/System.String
    l: System.String
condition:
  v: ele-1
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.teardown.action.extension
path:
  v: TestScript.teardown.action.extension
slicing:
  discriminator:
    type:
      v: value
    path:
      v: url
  description:
    v: Extensions are always sliced by (at least) url
  rules:
    v: open
short:
  v: Additional content defined by implementations
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
alias:
  v: extensions
alias:
  v: user content
min:
  v: 0
max:
  v: *
base:
  path:
    v: Element.extension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.teardown.action.modifierExtension
path:
  v: TestScript.teardown.action.modifierExtension
short:
  v: Extensions that cannot be ignored even if unrecognized
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions. Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
requirements:
  v: Modifier extensions allow for extensions that *cannot* be safely ignored to be clearly distinguished from the vast majority of extensions which can be safely ignored. This promotes interoperability by eliminating the need for implementers to prohibit the presence of extensions. For further information, see the [definition of modifier extensions](http://build.fhir.org/extensibility.html#modifierExtension).
alias:
  v: extensions
alias:
  v: user content
alias:
  v: modifiers
min:
  v: 0
max:
  v: *
base:
  path:
    v: BackboneElement.modifierExtension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: true
is modifier reason:
  v: Modifier extensions are expected to modify the meaning or interpretation of the element that contains them
is summary:
  v: true
mapping:
  identity:
    v: rim
  map:
    v: N/A

id:
  v: TestScript.teardown.action.common
path:
  v: TestScript.teardown.action.common
short:
  v: Links or references to common collection(s) of actions
definition:
  v: Links or references to common collection(s) of actions in this or an external TestScript instance. Action asserts SHALL be ignored for the TestScript.teardown.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.teardown.action.common
  min:
    v: 0
  max:
    v: 1
content reference:
  v: http://hl7.org/fhir/StructureDefinition/TestScript#TestScript.setup.action.common
  l: TestScript.setup.action.common
type:
  code:
    v: BackboneElement
    l: BackboneElement

id:
  v: TestScript.teardown.action.operation
path:
  v: TestScript.teardown.action.operation
short:
  v: The teardown operation to perform
definition:
  v: An operation would involve a REST request to a server.
min:
  v: 1
max:
  v: 1
base:
  path:
    v: TestScript.teardown.action.operation
  min:
    v: 1
  max:
    v: 1
content reference:
  v: http://hl7.org/fhir/StructureDefinition/TestScript#TestScript.setup.action.operation
  l: TestScript.setup.action.operation
constraint:
  key:
    v: tst-15
  severity:
    v: error
  human:
    v: Teardown operation SHALL contain either sourceId or targetId or params or url.
  expression:
    v: sourceId.exists() or (targetId.count() + url.count() + params.count() = 1) or (type.code in ('capabilities' | 'search' | 'transaction' | 'history'))
  source:
    v: http://hl7.org/fhir/StructureDefinition/TestScript
    l: TestScript

id:
  v: TestScript.common
path:
  v: TestScript.common
short:
  v: A common collection of actions in this script
definition:
  v: A common collection of actions that can be re-used in a TestScript.
min:
  v: 0
max:
  v: *
base:
  path:
    v: TestScript.common
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: BackboneElement
    l: BackboneElement
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children or both
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element

id:
  v: TestScript.common.id
path:
  v: TestScript.common.id
representation:
  v: xmlAttr
short:
  v: Unique id for inter-element referencing
definition:
  v: Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Element.id
  min:
    v: 0
  max:
    v: 1
type:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
      l: structuredefinition-fhir-type
    value: Url
      v: id
      l: id
  code:
    v: http://hl7.org/fhirpath/System.String
    l: System.String
condition:
  v: ele-1
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.common.extension
path:
  v: TestScript.common.extension
slicing:
  discriminator:
    type:
      v: value
    path:
      v: url
  description:
    v: Extensions are always sliced by (at least) url
  rules:
    v: open
short:
  v: Additional content defined by implementations
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
alias:
  v: extensions
alias:
  v: user content
min:
  v: 0
max:
  v: *
base:
  path:
    v: Element.extension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.common.modifierExtension
path:
  v: TestScript.common.modifierExtension
short:
  v: Extensions that cannot be ignored even if unrecognized
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions. Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
requirements:
  v: Modifier extensions allow for extensions that *cannot* be safely ignored to be clearly distinguished from the vast majority of extensions which can be safely ignored. This promotes interoperability by eliminating the need for implementers to prohibit the presence of extensions. For further information, see the [definition of modifier extensions](http://build.fhir.org/extensibility.html#modifierExtension).
alias:
  v: extensions
alias:
  v: user content
alias:
  v: modifiers
min:
  v: 0
max:
  v: *
base:
  path:
    v: BackboneElement.modifierExtension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: true
is modifier reason:
  v: Modifier extensions are expected to modify the meaning or interpretation of the element that contains them
is summary:
  v: true
mapping:
  identity:
    v: rim
  map:
    v: N/A

id:
  v: TestScript.common.key
path:
  v: TestScript.common.key
short:
  v: Key that identifies this common collection of actions
definition:
  v: Key that identifies this common collection of actions (unique within this resource).
min:
  v: 1
max:
  v: 1
base:
  path:
    v: TestScript.common.key
  min:
    v: 1
  max:
    v: 1
type:
  code:
    v: id
    l: id

id:
  v: TestScript.common.name
path:
  v: TestScript.common.name
short:
  v: Tracking/logging name of this common collection of actions
definition:
  v: The name of this this common collection of actions used for tracking/logging purposes by test engines.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.common.name
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string

id:
  v: TestScript.common.description
path:
  v: TestScript.common.description
short:
  v: Tracking/reporting short description of this common collection of actions
definition:
  v: A short description of this common collection of actions used by test engines for tracking and reporting purposes.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.common.description
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string

id:
  v: TestScript.common.parameter
extension:
  url:
    v: http://hl7.org/fhir/StructureDefinition/structuredefinition-explicit-type-name
    l: structuredefinition-explicit-type-name
  value: String
    v: CommonParameter
path:
  v: TestScript.common.parameter
short:
  v: Parameter(s) to convey input values to this common collection of actions in this script
definition:
  v: Optional named parameter(s) to provide input values to this common collection of actions from this or an external TestScript.
min:
  v: 0
max:
  v: *
base:
  path:
    v: TestScript.common.parameter
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: BackboneElement
    l: BackboneElement
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children or both
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element

id:
  v: TestScript.common.parameter.id
path:
  v: TestScript.common.parameter.id
representation:
  v: xmlAttr
short:
  v: Unique id for inter-element referencing
definition:
  v: Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Element.id
  min:
    v: 0
  max:
    v: 1
type:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
      l: structuredefinition-fhir-type
    value: Url
      v: id
      l: id
  code:
    v: http://hl7.org/fhirpath/System.String
    l: System.String
condition:
  v: ele-1
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.common.parameter.extension
path:
  v: TestScript.common.parameter.extension
slicing:
  discriminator:
    type:
      v: value
    path:
      v: url
  description:
    v: Extensions are always sliced by (at least) url
  rules:
    v: open
short:
  v: Additional content defined by implementations
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
alias:
  v: extensions
alias:
  v: user content
min:
  v: 0
max:
  v: *
base:
  path:
    v: Element.extension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.common.parameter.modifierExtension
path:
  v: TestScript.common.parameter.modifierExtension
short:
  v: Extensions that cannot be ignored even if unrecognized
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions. Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
requirements:
  v: Modifier extensions allow for extensions that *cannot* be safely ignored to be clearly distinguished from the vast majority of extensions which can be safely ignored. This promotes interoperability by eliminating the need for implementers to prohibit the presence of extensions. For further information, see the [definition of modifier extensions](http://build.fhir.org/extensibility.html#modifierExtension).
alias:
  v: extensions
alias:
  v: user content
alias:
  v: modifiers
min:
  v: 0
max:
  v: *
base:
  path:
    v: BackboneElement.modifierExtension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: true
is modifier reason:
  v: Modifier extensions are expected to modify the meaning or interpretation of the element that contains them
is summary:
  v: true
mapping:
  identity:
    v: rim
  map:
    v: N/A

id:
  v: TestScript.common.parameter.name
path:
  v: TestScript.common.parameter.name
short:
  v: Tracking/logging name of this parameter to be used in this common collection of actions
definition:
  v: The name of this parameter that will referenced in this common collection of actions using the TestScript variable nomenclature '${name}.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.common.parameter.name
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string

id:
  v: TestScript.common.parameter.description
path:
  v: TestScript.common.parameter.description
short:
  v: Tracking/reporting short description of this parameter to be used this common collection of actions
definition:
  v: An optional short description of this parameter to be used this common collection of actions used by test engines for tracking and reporting purposes.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.common.parameter.description
  min:
    v: 0
  max:
    v: 1
type:
  code:
    v: string
    l: string

id:
  v: TestScript.common.action
extension:
  url:
    v: http://hl7.org/fhir/StructureDefinition/structuredefinition-explicit-type-name
    l: structuredefinition-explicit-type-name
  value: String
    v: CommonAction
path:
  v: TestScript.common.action
short:
  v: A common operation or assert that can be re-used in this script
definition:
  v: An action will contain either an operation or an assertion but not both.
min:
  v: 1
max:
  v: *
base:
  path:
    v: TestScript.common.action
  min:
    v: 1
  max:
    v: *
type:
  code:
    v: BackboneElement
    l: BackboneElement
constraint:
  key:
    v: tst-16
  severity:
    v: error
  human:
    v: Common action SHALL contain either an operation or assert but not both.
  expression:
    v: operation.exists() xor assert.exists()
  source:
    v: http://hl7.org/fhir/StructureDefinition/TestScript
    l: TestScript
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children or both
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element

id:
  v: TestScript.common.action.id
path:
  v: TestScript.common.action.id
representation:
  v: xmlAttr
short:
  v: Unique id for inter-element referencing
definition:
  v: Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: Element.id
  min:
    v: 0
  max:
    v: 1
type:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/structuredefinition-fhir-type
      l: structuredefinition-fhir-type
    value: Url
      v: id
      l: id
  code:
    v: http://hl7.org/fhirpath/System.String
    l: System.String
condition:
  v: ele-1
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.common.action.extension
path:
  v: TestScript.common.action.extension
slicing:
  discriminator:
    type:
      v: value
    path:
      v: url
  description:
    v: Extensions are always sliced by (at least) url
  rules:
    v: open
short:
  v: Additional content defined by implementations
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
alias:
  v: extensions
alias:
  v: user content
min:
  v: 0
max:
  v: *
base:
  path:
    v: Element.extension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: false
is summary:
  v: false
mapping:
  identity:
    v: rim
  map:
    v: n/a

id:
  v: TestScript.common.action.modifierExtension
path:
  v: TestScript.common.action.modifierExtension
short:
  v: Extensions that cannot be ignored even if unrecognized
definition:
  v: May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions. Modifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself).
comment:
  v: There can be no stigma associated with the use of extensions by any application, project, or standard - regardless of the institution or jurisdiction that uses or defines the extensions. The use of extensions is what allows the FHIR specification to retain a core level of simplicity for everyone.
requirements:
  v: Modifier extensions allow for extensions that *cannot* be safely ignored to be clearly distinguished from the vast majority of extensions which can be safely ignored. This promotes interoperability by eliminating the need for implementers to prohibit the presence of extensions. For further information, see the [definition of modifier extensions](http://build.fhir.org/extensibility.html#modifierExtension).
alias:
  v: extensions
alias:
  v: user content
alias:
  v: modifiers
min:
  v: 0
max:
  v: *
base:
  path:
    v: BackboneElement.modifierExtension
  min:
    v: 0
  max:
    v: *
type:
  code:
    v: Extension
    l: Extension
constraint:
  key:
    v: ele-1
  severity:
    v: error
  human:
    v: All FHIR elements must have a @value or children
  expression:
    v: hasValue() or (children().count() > id.count())
  source:
    v: http://hl7.org/fhir/StructureDefinition/Element
    l: Element
is modifier:
  v: true
is modifier reason:
  v: Modifier extensions are expected to modify the meaning or interpretation of the element that contains them
is summary:
  v: true
mapping:
  identity:
    v: rim
  map:
    v: N/A

id:
  v: TestScript.common.action.operation
path:
  v: TestScript.common.action.operation
short:
  v: The common operation that can be re-used in this script
definition:
  v: An operation would involve a REST request to a server.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.common.action.operation
  min:
    v: 0
  max:
    v: 1
content reference:
  v: http://hl7.org/fhir/StructureDefinition/TestScript#TestScript.setup.action.operation
  l: TestScript.setup.action.operation
constraint:
  key:
    v: tst-17
  severity:
    v: error
  human:
    v: Common operation SHALL contain either sourceId or targetId or params or url.
  expression:
    v: sourceId.exists() or (targetId.count() + url.count() + params.count() = 1) or (type.code in ('capabilities' | 'search' | 'transaction' | 'history'))
  source:
    v: http://hl7.org/fhir/StructureDefinition/TestScript
    l: TestScript

id:
  v: TestScript.common.action.assert
path:
  v: TestScript.common.action.assert
short:
  v: The common assertion to perform
definition:
  v: Evaluates the results of previous operations to determine if the server under test behaves appropriately.
comment:
  v: In order to evaluate an assertion, the request, response, and results of the most recently executed operation must always be maintained by the test engine.
min:
  v: 0
max:
  v: 1
base:
  path:
    v: TestScript.common.action.assert
  min:
    v: 0
  max:
    v: 1
content reference:
  v: http://hl7.org/fhir/StructureDefinition/TestScript#TestScript.setup.action.assert
  l: TestScript.setup.action.assert
constraint:
  key:
    v: tst-18
  severity:
    v: error
  human:
    v: Common action assert SHALL contain either compareToSourceId and compareToSourceExpression, compareToSourceId and compareToSourcePath or neither.
  expression:
    v: compareToSourceId.empty() xor (compareToSourceExpression.exists() or compareToSourcePath.exists())
  source:
    v: http://hl7.org/fhir/StructureDefinition/TestScript
    l: TestScript
constraint:
  key:
    v: tst-19
  severity:
    v: error
  human:
    v: Common action assert response and response and responseCode SHALL be empty when direction equals request
  expression:
    v: (response.empty() and responseCode.empty() and direction = 'request') or direction.empty() or direction = 'response'
  source:
    v: http://hl7.org/fhir/StructureDefinition/TestScript
    l: TestScript
constraint:
  key:
    v: tst-20
  severity:
    v: error
  human:
    v: A common action assert SHALL define a singular assertion function and prevent overlapping assertion functionality.
  expression:
    v: extension.exists() or (contentType.count() + expression.count() + headerField.count() + minimumId.count() + navigationLinks.count() + path.count() + requestMethod.count() + requestURL.count() + resource.count() + responseCode.count() + response.count() + validateProfileId.count() <= 1)
  source:
    v: http://hl7.org/fhir/StructureDefinition/TestScript
    l: TestScript
constraint:
  key:
    v: tst-21
  severity:
    v: error
  human:
    v: A common action assert SHALL not allow the use of operator and value with minimumId, navigationLinks or validateProfileId.
  expression:
    v: extension.exists() or (minimumId.count() + navigationLinks.count() + validateProfileId.count() = 0) or (minimumId.count() + navigationLinks.count() + validateProfileId.count() = 1 and operator.count() + value.count() = 0)
  source:
    v: http://hl7.org/fhir/StructureDefinition/TestScript
    l: TestScript

element:
  id:
    v: TestScript
  path:
    v: TestScript
  short:
    v: Describes a set of tests
  definition:
    v: A structured set of tests against a FHIR server or client implementation to determine compliance against the FHIR specification.
  min:
    v: 1
  max:
    v: 1
  constraint:
    key:
      v: cnl-0
    severity:
      v: warning
    human:
      v: Name should be usable as an identifier for the module by machine processing applications such as code generation
    expression:
      v: name.exists() implies name.matches('^[A-Z]([A-Za-z0-9_]){1,254}$')
    source:
      v: http://hl7.org/fhir/StructureDefinition/TestScript
      l: TestScript
  mapping:
    identity:
      v: workflow
    map:
      v: Definition
  mapping:
    identity:
      v: rim
    map:
      v: n/a
  mapping:
    identity:
      v: w5
    map:
      v: conformance.misc
element:
  id:
    v: TestScript.url
  path:
    v: TestScript.url
  short:
    v: Canonical identifier for this test script, represented as a URI (globally unique)
  definition:
    v: An absolute URI that is used to identify this test script when it is referenced in a specification, model, design or an instance; also called its canonical identifier. This SHOULD be globally unique and SHOULD be a literal address at which an authoritative instance of this test script is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the test script is stored on different servers.
  comment:
    v: Can be a urn:uuid: or a urn:oid: but real http: addresses are preferred. Multiple instances may share the same URL if they have a distinct version. The determination of when to create a new version of a resource (same url, new version) vs. defining a new artifact is up to the author. Considerations for making this decision are found in [Technical and Business Versions](resource.html#versions). In some cases, the resource can no longer be found at the stated url, but the url itself cannot change. Implementations can use the [meta.source](resource.html#meta) element to indicate where the current master source of the resource can be found.
  requirements:
    v: Allows the test script to be referenced by a single globally unique identifier.
  alias:
    v: url
  alias:
    v: authoritative-url
  alias:
    v: destination
  alias:
    v: identity
  min:
    v: 0
  max:
    v: 1
  type:
    code:
      v: uri
      l: uri
  is summary:
    v: true
  mapping:
    identity:
      v: workflow
    map:
      v: Definition.url
  mapping:
    identity:
      v: w5
    map:
      v: FiveWs.identifier
element:
  id:
    v: TestScript.identifier
  path:
    v: TestScript.identifier
  short:
    v: Additional identifier for the test script
  definition:
    v: A formal identifier that is used to identify this test script when it is represented in other formats, or referenced in a specification, model, design or an instance.
  requirements:
    v: Allows externally provided and/or usable business identifiers to be easily associated with the module.
  min:
    v: 0
  max:
    v: *
  type:
    code:
      v: Identifier
      l: Identifier
  is summary:
    v: true
  mapping:
    identity:
      v: workflow
    map:
      v: Definition.identifier
  mapping:
    identity:
      v: w5
    map:
      v: FiveWs.identifier
  mapping:
    identity:
      v: objimpl
    map:
      v: no-gen-base
element:
  id:
    v: TestScript.version
  path:
    v: TestScript.version
  short:
    v: Business version of the test script
  definition:
    v: The identifier that is used to identify this version of the test script when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the test script author and is not expected to be globally unique. For example, it might be a timestamp (e.g. yyyymmdd) if a managed version is not available. There is also no expectation that versions can be placed in a lexicographical sequence.
  comment:
    v: There may be different test script instances that have the same identifier but different versions. The version can be appended to the url in a reference to allow a reference to a particular business version of the test script with the format [url]|[version]. The version SHOULD NOT contain a '#' - see [Business Version](resource.html#bv-format).
  min:
    v: 0
  max:
    v: 1
  type:
    code:
      v: string
      l: string
  is summary:
    v: true
  mapping:
    identity:
      v: workflow
    map:
      v: Definition.version
  mapping:
    identity:
      v: w5
    map:
      v: FiveWs.version
element:
  id:
    v: TestScript.versionAlgorithm[x]
  path:
    v: TestScript.versionAlgorithm[x]
  short:
    v: How to compare versions
  definition:
    v: Indicates the mechanism used to compare versions to determine which is more current.
  comment:
    v: If set as a string, this is a FHIRPath expression that has two additional context variables passed in - %version1 and %version2 and will return a negative number if version1 is newer, a positive number if version2 and a 0 if the version ordering can't be successfully be determined.
  min:
    v: 0
  max:
    v: 1
  type:
    code:
      v: string
      l: string
  type:
    code:
      v: Coding
      l: Coding
  is summary:
    v: true
  binding:
    strength:
      v: extensible
    value set:
      v: http://hl7.org/fhir/ValueSet/version-algorithm
      l: version-algorithm
element:
  id:
    v: TestScript.name
  path:
    v: TestScript.name
  short:
    v: Name for this test script (computer friendly)
  definition:
    v: A natural language name identifying the test script. This name should be usable as an identifier for the module by machine processing applications such as code generation.
  comment:
    v: The name is not expected to be globally unique. The name should be a simple alphanumeric type name to ensure that it is machine-processing friendly.
  requirements:
    v: Support code generation.
  min:
    v: 1
  max:
    v: 1
  type:
    code:
      v: string
      l: string
  condition:
    v: cnl-0

v: true

identity:
  v: workflow
map:
  v: Definition.name

id:
  v: TestScript.title
extension:
  url:
    v: http://hl7.org/fhir/StructureDefinition/elementdefinition-translatable
    l: elementdefinition-translatable
  value: Boolean
    v: true
path:
  v: TestScript.title
short:
  v: Name for this test script (human friendly)
definition:
  v: A short, descriptive, user-friendly title for the test script.
comment:
  v: This name does not need to be machine-processing friendly and may contain punctuation, white-space, etc.
min:
  v: 0
max:
  v: 1
type:
  code:
    v: string
    l: string
is summary:
  v: true
mapping:
  identity:
    v: workflow
  map:
    v: Definition.title

id:
  v: TestScript.status
path:
  v: TestScript.status
short:
  v: draft | active | retired | unknown
definition:
  v: The status of this test script. Enables tracking the life-cycle of the content.
comment:
  v: Allows filtering of test scripts that are appropriate for use versus not. See guidance around (not) making local changes to elements [here](canonicalresource.html#localization).
min:
  v: 1
max:
  v: 1
type:
  code:
    v: code
    l: code
is modifier:
  v: true
is modifier reason:
  v: This is labeled as "Is Modifier" because applications should not use a retired {{title}} without due consideration
is summary:
  v: true
binding:
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-bindingName
      l: elementdefinition-bindingName
    value: String
      v: PublicationStatus
  extension:
    url:
      v: http://hl7.org/fhir/StructureDefinition/elementdefinition-isCommonBinding
      l: elementdefinition-isCommonBinding
    value: Boolean
      v: true
  strength:
    v: required