Name | Flags | Card. | Type | Description & Constraints |
---|---|---|---|---|
TestScript | DomainResource | Describes a set of tests | ||
url | Σ | 1..1 | uri | Absolute URL used to reference this TestScript |
version | Σ | 0..1 | string | Logical id for this version of the TestScript |
name | Σ | 1..1 | string | Informal name for this TestScript |
status | ?! Σ | 1..1 | code | draft | active | retired
ConformanceResourceStatus ( Required) |
identifier | Σ | 0..1 | Identifier | External identifier |
experimental | Σ | 0..1 | boolean | If for testing purposes, not real usage |
publisher | Σ | 0..1 | string | Name of the publisher (Organization or individual) |
contact | Σ | 0..* | BackboneElement | Contact details of the publisher |
name | Σ | 0..1 | string | Name of a individual to contact |
telecom | Σ | 0..* | ContactPoint | Contact details for individual or publisher |
date | Σ | 0..1 | dateTime | Date for this version of the TestScript |
description | Σ | 0..1 | string | Natural language description of the TestScript |
useContext | Σ | 0..* | CodeableConcept | Content intends to support these contexts
Context of Use ValueSet ( Extensible) |
requirements | 0..1 | string | Scope and Usage this Test Script is for | |
copyright | 0..1 | string | Use and/or publishing restrictions | |
metadata | I | 0..1 | BackboneElement | Required capability that is assumed to function correctly on the FHIR server being tested
TestScript metadata capability SHALL contain required or validated or both. |
link | 0..* | BackboneElement | Links to the FHIR specification | |
url | 1..1 | uri | URL to the specification | |
description | 0..1 | string | Short description | |
capability | 1..* | BackboneElement | Capabilities that are assumed to function correctly on the FHIR server being tested | |
required | 0..1 | boolean | Are the capabilities required? | |
validated | 0..1 | boolean | Are the capabilities validated? | |
description | 0..1 | string | The expected capabilities of the server | |
destination | 0..1 | integer | Which server these requirements apply to | |
link | 0..* | uri | Links to the FHIR specification | |
conformance | 1..1 | Reference( Conformance) | Required Conformance | |
multiserver | 0..1 | boolean | Whether or not the tests apply to more than one FHIR server | |
fixture | 0..* | BackboneElement | Fixture in the test script - by reference (uri) | |
autocreate | 0..1 | boolean | Whether or not to implicitly create the fixture during setup | |
autodelete | 0..1 | boolean | Whether or not to implicitly delete the fixture during teardown | |
resource | 0..1 | Reference( Any) | Reference of the resource | |
profile | 0..* | Reference( Any) | Reference of the validation profile | |
variable | I | 0..* | BackboneElement | Placeholder for evaluated elements
Variable cannot contain both headerField and path. |
name | 1..1 | string | Descriptive name for this variable | |
headerField | 0..1 | string | HTTP header field name for source | |
path | 0..1 | string | XPath or JSONPath against the fixture body | |
sourceId | 0..1 | id | Fixture Id of source expression or headerField within this variable | |
setup | 0..1 | BackboneElement | A series of required setup operations before tests are executed | |
metadata | I | 0..1 | see metadata | Capabilities that are assumed to function correctly on the FHIR server being tested
Setup metadata capability SHALL contain required or validated or both. |
action | I | 1..* | BackboneElement | A setup operation or assert to perform
Setup action SHALL contain either an operation or assert but not both. |
operation | I | 0..1 | BackboneElement | The setup operation to perform
Setup operation SHALL contain either sourceId or targetId or params or url. |
type | 0..1 | Coding | The setup operation type that will be executed
TestScriptOperationCodes ( Extensible) |
|
resource | 0..1 | code | Resource type
FHIRDefinedType ( Required) |
|
label | 0..1 | string | Tracking/logging operation label | |
description | 0..1 | string | Tracking/reporting operation description | |
accept | 0..1 | code | xml | json
ContentType ( Required) |
|
contentType | 0..1 | code | xml | json
ContentType ( Required) |
|
destination | 0..1 | integer | Which server to perform the operation on | |
encodeRequestUrl | 0..1 | boolean | Whether or not to send the request url in encoded format | |
params | 0..1 | string | Explicitly defined path parameters | |
requestHeader | 0..* | BackboneElement | Each operation can have one ore more header elements | |
field | 1..1 | string | HTTP header field name | |
value | 1..1 | string | HTTP headerfield value | |
responseId | 0..1 | id | Fixture Id of mapped response | |
sourceId | 0..1 | id | Fixture Id of body for PUT and POST requests | |
targetId | 0..1 | id | Id of fixture used for extracting the [id], [type], and [vid] for GET requests | |
url | 0..1 | string | Request URL | |
assert | I | 0..1 | BackboneElement | The assertion to perform
Setup action assert shall contain both compareToSourceId and compareToSourcePath or neither. Only a single assertion SHALL be present within setup action assert element. |
label | 0..1 | string | Tracking/logging assertion label | |
description | 0..1 | string | Tracking/reporting assertion description | |
direction | 0..1 | code | response | request
AssertionDirectionType ( Required) |
|
compareToSourceId | 0..1 | string | Id of fixture used to compare the "sourceId/path" evaluations to | |
compareToSourcePath | 0..1 | string | XPath or JSONPath expression against fixture used to compare the "sourceId/path" evaluations to | |
contentType | 0..1 | code | xml | json
ContentType ( Required) |
|
headerField | 0..1 | string | HTTP header field name | |
minimumId | 0..1 | string | Fixture Id of minimum content resource | |
navigationLinks | 0..1 | boolean | Perform validation on navigation links? | |
operator | 0..1 | code | equals | notEquals | in | notIn | greaterThan | lessThan | empty | notEmpty | contains | notContains
AssertionOperatorType ( Required) |
|
path | 0..1 | string | XPath or JSONPath expression | |
resource | 0..1 | code | Resource type
FHIRDefinedType ( Required) |
|
response | 0..1 | code | okay | created | noContent | notModified | bad | forbidden | notFound | methodNotAllowed | conflict | gone | preconditionFailed | unprocessable
AssertionResponseTypes ( Required) |
|
responseCode | 0..1 | string | HTTP response code to test | |
sourceId | 0..1 | id | Fixture Id of source expression or headerField | |
validateProfileId | 0..1 | id | Profile Id of validation profile reference | |
value | 0..1 | string | The value to compare to | |
warningOnly | 0..1 | boolean | Will this assert produce a warning only on error? | |
test | 0..* | BackboneElement | A test in this script | |
name | 0..1 | string | Tracking/logging name of this test | |
description | 0..1 | string | Tracking/reporting short description of the test | |
metadata | I | 0..1 | see metadata | Capabilities that are expected to function correctly on the FHIR server being tested
Test metadata capability SHALL contain required or validated or both. |
action | I | 1..* | BackboneElement | A test operation or assert to perform
Test action SHALL contain either an operation or assert but not both. |
operation | I | 0..1 | see operation | The setup operation to perform
Test operation SHALL contain either sourceId or targetId or params or url. |
assert | I | 0..1 | see assert | The setup assertion to perform
Test action assert shall contain both compareToSourceId and compareToSourcePath or neither. Only a single assertion SHALL be present within test action assert element. |
teardown | 0..1 | BackboneElement | A series of required clean up steps | |
action | I | 1..* | BackboneElement | One or more teardown operations to perform
Teardown action SHALL contain an operation. |
operation | I | 0..1 | see operation | The teardown operation to perform
Teardown operation SHALL contain either sourceId or targetId or params or url. |
Documentation for this format |