FHIR CI-Build

This is the Continuous Integration Build of FHIR (will be incorrect/inconsistent at times).
See the Directory of published versions icon

FHIR Infrastructure icon Work GroupMaturity Level: 1 DraftSecurity Category: Business Compartments: No defined compartments

Detailed Descriptions for the elements in the TestPlan resource.

Element Id TestPlan
Definition

A set of test specifications that are able to be executed by a TestRunner that knows how to interpret the tests and execute them.

Short Display Tests to be executed by a Test Runner that knows the tests
Cardinality 0..*
Type CanonicalResource
Summary false
Constraints
Defined on this element
cnl-0Warning Name should be usable as an identifier for the module by machine processing applications such as code generationname.exists() implies name.matches('^[A-Z]([A-Za-z0-9_]){1,254}$')
Element Id TestPlan.url
Definition

An absolute URI that is used to identify this test plan 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 plan is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the test plan is stored on different servers.

Short Display Canonical identifier for this test plan, represented as a URI (globally unique)
Cardinality 0..1
Type uri
Requirements

Allows the test plan to be referenced by a single globally unique identifier.

Alternate Names url; authoritative-url; destination; identity
Summary true
Comments

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.

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 element to indicate where the current master source of the resource can be found.

Constraints
Defined on this element
cnl-1Warning URL should not contain | or # - these characters make processing canonical references problematicexists() implies matches('^[^|# ]+$')
Element Id TestPlan.identifier
Definition

A formal identifier that is used to identify this test plan when it is represented in other formats, or referenced in a specification, model, design or an instance.

Short Display Business identifier for the test plan
Note This is a business identifier, not a resource identifier (see discussion)
Cardinality 0..*
Type Identifier
Requirements

Allows externally provided and/or usable business identifiers to be easily associated with the module.

Summary true
Element Id TestPlan.version
Definition

The identifier that is used to identify this version of the test plan when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the test plan 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.

Short Display Business version of the test plan
Note This is a business versionId, not a resource version id (see discussion)
Cardinality 0..1
Type string
Summary true
Comments

There may be different test plan 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 plan with the format [url]|[version]. The version SHOULD NOT contain a '#' - see Business Version.

Element Id TestPlan.versionAlgorithm[x]
Definition

Indicates the mechanism used to compare versions to determine which is more current.

Short Display How to compare versions
Cardinality 0..1
Terminology Binding Version Algorithm (Extensible)
Type string|Coding
[x] Note See Choice of Datatypes for further information about how to use [x]
Summary true
Comments

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.

Element Id TestPlan.name
Definition

A natural language name identifying the test plan. This name should be usable as an identifier for the module by machine processing applications such as code generation.

Short Display Name for this test plan (computer friendly)
Cardinality 0..1
Type string
Requirements

Support code generation.

Summary true
Comments

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.

Constraints
Affect this element
cnl-0Warning Name should be usable as an identifier for the module by machine processing applications such as code generationname.exists() implies name.matches('^[A-Z]([A-Za-z0-9_]){1,254}$')
Element Id TestPlan.title
Definition

A short, descriptive, user-friendly title for the test plan.

Short Display Name for this test plan (human friendly)
Cardinality 0..1
Type string
Summary false
Comments

This name does not need to be machine-processing friendly and may contain punctuation, white-space, etc.

Element Id TestPlan.status
Definition

The status of this test plan. Enables tracking the life-cycle of the content.

Short Display draft | active | retired | unknown
Cardinality 1..1
Terminology Binding PublicationStatus (Required)
Type code
Is Modifier true (Reason: This is labeled as "Is Modifier" because applications should not use a retired {{title}} without due consideration)
Summary true
Comments

Allows filtering of test plans that are appropriate for use versus not.

See guidance around (not) making local changes to elements here.

Element Id TestPlan.experimental
Definition

A Boolean value to indicate that this test plan is authored for testing purposes (or education/evaluation/marketing) and no version of this resource will ever be intended for genuine usage.

Short Display For testing only - never for real usage
Cardinality 0..1
Type boolean
Meaning if Missing If absent, this resource is treated as though it is not experimental.
Requirements

Enables experimental content to be developed following the same lifecycle that would be used for a production-level test plan.

Summary true
Comments

Allows filtering of test plans that are appropriate for use versus not. Experimental resources might include example instances in implementation guides, instances created solely for testing purposes, etc. If experimental is 'true' for any version of a resource, it should be true for all versions of the resource. (If experimental changes, then it is being misused or a resource that was never intended for real-world use has unexpectedly changed its purpose.).

Experimental resources are not expected to be stable and may well have breaking changes without a corresponding change to the 'version' element.

Element Id TestPlan.date
Definition

The date (and optionally time) when the test plan 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 plan changes.

Short Display Date last changed
Cardinality 0..1
Type dateTime
Alternate Names Revision Date
Summary true
Comments

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 plan. 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.

Element Id TestPlan.publisher
Definition

The name of the organization or individual responsible for the release and ongoing maintenance of the test plan.

Short Display Name of the publisher/steward (organization or individual)
Cardinality 0..1
Type string
Requirements

Helps establish the "authority/credibility" of the test plan. May also allow for contact.

Summary true
Comments

Usually an organization but may be an individual. The publisher (or steward) of the test plan is the organization or individual primarily responsible for the maintenance and upkeep of the test plan. 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 plan. This item SHOULD be populated unless the information is available from context.

Element Id TestPlan.contact
Definition

Contact details to assist a user in finding and communicating with the publisher.

Short Display Contact details for the publisher
Cardinality 0..*
Type ContactDetail
Summary true
Comments

May be a web site, an email address, a telephone number, etc.

See guidance around (not) making local changes to elements here.

Element Id TestPlan.description
Definition

A free text natural language description of the test plan from a consumer's perspective.

Short Display Natural language description of the test plan
Cardinality 0..1
Type markdown
Summary false
Comments

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 plan 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 plan is presumed to be the predominant language in the place the test plan was created).

Element Id TestPlan.useContext
Definition

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 plan instances.

Short Display The context that the content is intended to support
Cardinality 0..*
Type UsageContext
Requirements

Assist in searching for appropriate content.

Summary true
Comments

When multiple useContexts are specified, there is no expectation that all or any of the contexts apply.

Element Id TestPlan.jurisdiction
Definition

A legal or geographic region in which the test plan is intended to be used.

Short Display Intended jurisdiction where the test plan applies (if applicable)
Cardinality 0..*
Terminology Binding Jurisdiction ValueSet (Extensible)
Type CodeableConcept
Summary true
Comments

It may be possible for the test plan 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.)

Element Id TestPlan.purpose
Definition

Explanation of why this test plan is needed and why it has been designed as it has.

Short Display Why this test plan is defined
Cardinality 0..1
Type markdown
Summary false
Comments

This element does not describe the usage of the test plan 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 plan.

Element Id TestPlan.copyright
Definition

A copyright statement relating to the test plan and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the test plan. The short copyright declaration (e.g. (c) '2015+ xyz organization' should be sent in the copyrightLabel element.

Short Display Use and/or publishing restrictions
Cardinality 0..1
Type markdown
Requirements

Consumers must be able to determine any legal restrictions on the use of the test plan and/or its content.

Alternate Names License; Restrictions
Summary false
Element Id TestPlan.copyrightLabel
Definition

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').

Short Display Copyright holder and year(s)
Cardinality 0..1
Type string
Requirements

Defines the content expected to be rendered in all representations of the artifact.

Summary false
Comments

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.

Element Id TestPlan.scope
Definition

The scope indicates what kind of systems these test cases are intended to test.

Short Display The scope - what these test cases are testing
Cardinality 0..*
Type Base
Summary false
Element Id TestPlan.scope.reference
Definition

A reference to what is being tested.

Short Display A reference to what is being tested
Cardinality 0..1
Type canonical(ActorDefinition | ImplementationGuide | StructureDefinition | CapabilityStatement | Requirements)
Summary false
Element Id TestPlan.scope.description
Definition

Description of what the scope is does / what is being tested.

Short Display Description of what the scope is exists / what is being tested
Cardinality 0..1
Type string
Summary false
Element Id TestPlan.dependency
Definition

Another set of test cases that must be passed before these test cases are meaningful to execute. These test cases prove functionality that these tests require to execute.

Short Display Test cases that must be passed before these test cases are meaningful to execute
Cardinality 0..*
Type Base
Summary false
Element Id TestPlan.dependency.reference
Definition

The test cases.

Short Display The Test Cases
Cardinality 1..1
Type canonical(TestPlan)
Summary false
Element Id TestPlan.dependency.description
Definition

Description of what this mode does / why it was defined. This should explain to a tester why the .

Short Display Description of what the dependency exists / why it was defined
Cardinality 0..1
Type string
Summary false
Element Id TestPlan.runner
Definition

URL of documentation that explains how a runner would read these tests, and use them to actually test out a tool.

Short Display URL Documentation for a runner that executes these tests
Cardinality 1..1
Type url
Summary true
Element Id TestPlan.mode
Definition

A mode that can be passed to a runner running these these tests, that affects test content and influences how the tests are executed or evaulated (or even if they run).

Short Display A mode that can be passed to runner - affects test content
Cardinality 0..*
Type Base
Summary false
Element Id TestPlan.mode.code
Definition

The code by which the mode is identified when passed to runner. This code is used to select which suite and tests are run, and which parameters and inputs are used. Codes are entirely at the descretion of the TestPlan, but typically 'advanced' or 'general' are the kind of codes that could be used.

Short Display The code that identifies the mode
Cardinality 1..1
Type string
Requirements

Allows the runner to select which tests and parameters are relevant for this mode.

Summary false
Comments

The code should be a simple alphanumeric type name to ensure that it is machine-processing friendly.

Element Id TestPlan.mode.description
Definition

Description of what this mode does / why it was defined. This should explain to a tester when they should use the mode.

Short Display Description of what this mode exists / why it was defined
Cardinality 0..1
Type string
Summary false
Element Id TestPlan.parameter
Definition

A parameter passed to the runner when executing tests. Which parameters are valid, and how exactly the parameter is used are used depends on the definition of the runner.

Short Display Parameter defined for all tests
Cardinality 0..*
Type Base
Summary false
Element Id TestPlan.parameter.name
Definition

Name for the parameter as defined by the runner definition.

Short Display Name per Runner Definition
Cardinality 1..1
Type string
Summary false
Element Id TestPlan.parameter.value[x]
Definition

The value of the parameter. If the value is an Expression, the definition of the runner describes what kind of expressions are allowed and the features/capabilities that they can make use of.

Short Display Value of this parameter
Cardinality 1..1
Type string|boolean|integer|decimal|dateTime|uri|Coding|Quantity|Expression
[x] Note See Choice of Datatypes for further information about how to use [x]
Summary false
Element Id TestPlan.parameter.mode
Definition

If this mode is not passed to the runner, then this parameter will not be used.

Short Display A mode that must be true for this parameter to be used
Cardinality 0..1
Type code
Meaning if Missing If no modes are listed, the parameter is always used, unless there is a parameter with the same name that is selected by mode
Summary false
Element Id TestPlan.suite
Definition

A suite of tests that all share a common set up, and can be executed as a group.

Short Display A suite of tests that share a common set up
Cardinality 0..*
Type Base
Summary false
Element Id TestPlan.suite.name
Definition

The name by which this suite is known by in the test system. The name must be unique in the amongst the suites.

Short Display The name of this suite - unique in the TestCases resource
Cardinality 1..1
Type string
Summary false
Element Id TestPlan.suite.description
Definition

Description of what this suite does / why it was defined. This should explain to a tester what they should know when deciding which tests to run.

Short Display Description of what this suite does / why it was defined
Cardinality 0..1
Type string
Summary false
Element Id TestPlan.suite.mode
Definition

If this mode is not passed to the runner, then this suite will not be run.

Short Display Mode required to run this suite
Cardinality 0..1
Type code
Meaning if Missing If no modes are listed, the suite is always executed
Summary false
Element Id TestPlan.suite.input
Definition

The resources used in the tests in this suite. How exactly they are used depends on the definition of the runner .

Short Display Resources used in the tests in this suite
Cardinality 0..*
Type Base
Summary false
Constraints
Defined on this element
tp-1Rule Either a file, or a resource, but not bothfile.exists() xor resource.exists()
Element Id TestPlan.suite.input.name
Definition

A name that identifies this resource. The runner definition defines whether there must be a name, and what names there are.

Short Display A name for this resource (per runner definition)
Cardinality 0..1
Type string
Summary false
Element Id TestPlan.suite.input.file
Definition

A file containing a resource used in the tests.

Short Display A file containing a resource used in the tests
Cardinality 0..1
Type string
Summary false
Comments

Filename is relative to the folder/directory containing this TestCases

Element Id TestPlan.suite.input.resource
Definition

An inline resource used in the tests. How exactly it is used depends on the definition of the runner.

Short Display An inline resource used in the tests
Cardinality 0..1
Type Resource
Summary false
Element Id TestPlan.suite.input.mode
Definition

If this mode is not passed to the runner, then this resource will not be used.

Short Display A mode that must be true for this resource to be used
Cardinality 0..1
Type code
Meaning if Missing If no modes are listed, the resource is always used, unless there is another entry with the same name that is selected by mode
Summary false
Element Id TestPlan.suite.parameter
Definition

A parameter passed to the runner when executing tests. Which parameters are valid, and how exactly the parameter is used are used depends on the definition of the runner.

Short Display Parameter defined by the suite
Cardinality 0..*
Type See TestPlan.parameter
Summary false
Element Id TestPlan.suite.test
Definition

An actual test in the test suite.

Short Display A test in the test suite
Cardinality 0..*
Type Base
Summary false
Element Id TestPlan.suite.test.name
Definition

The name by which this test is known by in the test system. The name must be unique in the suite.

Short Display The name of this test - unique in the suite
Cardinality 1..1
Type string
Summary false
Element Id TestPlan.suite.test.description
Definition

Description of what this test does / why it was defined. This should explain to a tester what they should know when looking at failing test results.

Short Display Description of what this test does / why it was defined
Cardinality 0..1
Type string
Summary false
Element Id TestPlan.suite.test.operation
Definition

A code that identifies the operation executed for this test. One of the codes defined in the definition of the runner.

Short Display Operation that is executed during this test (per definition of runner)
Cardinality 0..1
Type code
Summary false
Element Id TestPlan.suite.test.mode
Definition

If this mode is not passed to the runner, then this test will not be run.

Short Display Mode required to run this test
Cardinality 0..1
Type code
Meaning if Missing If no modes are listed, the test is always executed
Summary false
Element Id TestPlan.suite.test.parameter
Definition

A parameter passed to the runner when executing tests. Which parameters are valid, and how exactly the parameter is used are used depends on the definition of the runner.

Short Display Parameter defined by the test
Cardinality 0..*
Type See TestPlan.parameter
Summary false
Element Id TestPlan.suite.test.input
Definition

The resources used when executing this test. How exactly they are used depends on the definition of the runner.

Short Display Resources used when executing this test (per runner definition)
Cardinality 0..*
Type See TestPlan.suite.input
Summary false
Element Id TestPlan.suite.test.expected
Definition

Resources expected as output from this test. Often, but not always, these resources are Matchetype resources. How exactly it is used depends on the definition of the runner. How exactly it is used depends on the definition of the runner, but the expectation is that these are the expected output, to which the actual output is compared.

Short Display Resources expected as output from this test (per runner definition, often Matchetypes)
Cardinality 0..*
Type See TestPlan.suite.input
Summary false
Element Id TestPlan.suite.test.assertion
Definition

One or more assertions that can be executed against the output of the tests. These may be used with matchetypes to make rules about content the matchetypes leave open.

Short Display Assertions that can be executed against the output of the tests
Cardinality 0..*
Type Base
Summary false
Constraints
Defined on this element
tp-2Rule At least an expression or a human readable rule must existexpression.exists() or human.exists()
Element Id TestPlan.suite.test.assertion.focus
Definition

Resources expected as output from this test. Often, but not always, these resources are Matchetype resources.

Short Display Which output the assertion is tested on (by name, if there is more than one)
Cardinality 0..1
Type string
Summary false
Element Id TestPlan.suite.test.assertion.severity
Definition

Resources expected as output from this test. Only error and fatal assertions are considered to cause a test to fail. Often, but not always, these resources are Matchetype resources. How exactly it is used depends on the definition of the runner.

Short Display fatal | error | warning | information | success; fatal+error = fail
Cardinality 0..1
Terminology Binding Issue Severity (Required)
Type code
Summary false
Element Id TestPlan.suite.test.assertion.expression
Definition

Resources expected as output from this test. Often, but not always, these resources are Matchetype resources. How exactly it is used depends on the definition of the runner.

Short Display Technical Expression of the assertion
Cardinality 0..1
Type Expression
Summary false
Element Id TestPlan.suite.test.assertion.human
Definition

A human readable description of the assertion.

Short Display Human readable description of the assertion
Cardinality 0..1
Type string
Summary false
Element Id TestPlan.suite.test.assertion.mode
Definition

If this mode is not passed to the runner, then this assertion will not be used.

Short Display A mode that must be true for this assertion to apply
Cardinality 0..1
Type code
Meaning if Missing If no modes are listed, the assertion is always used, unless there is another assertion with the same name that is selected by mode
Summary false
Element Id TestPlan.suite.suite
Definition

A nested set of tests.

Short Display A nested suite of tests
Cardinality 0..*
Type See TestPlan.suite
Summary false
Element Id TestPlan.suite.plan
Definition

A nested set of test plans that run within the context of this suite. Typically, the runner must be the same in the nested test plans.

Short Display A nested set of test plans
Cardinality 0..*
Type Reference(TestPlan)
Summary false
Comments

This is a reference to allow for direct local file references etc, but since TestPlan is a CanonicalResource, it can also be resolved as a canonical reference.