Unit Test Results.

Designed for use with JUnit and Ant.

Class org.openhealthtools.mdht.uml.cda.consol.tests.EstimatedDateOfDeliveryTest

NameTestsErrorsFailuresTime(s)Time StampHost
EstimatedDateOfDeliveryTest7000.1762013-01-31T13:34:53JKMSoftware-desktop

Tests

NameStatusResultTime(s)
testConstructor

Constraint

OCL

SuccessInvalid XML

Valid XML

0.001
testValidateEstimatedDateOfDeliveryTemplateId

Constraint

SHALL contain exactly one [1..1] templateId ( CONF:16762, CONF:16763 ) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.15.3.1"

OCL

self.templateId->exists(id : datatypes::II | id.root = '2.16.840.1.113883.10.20.15.3.1')

SuccessInvalid XML


<observation xmlns="urn:hl7-org:v3"/>

Valid XML


<observation xmlns="urn:hl7-org:v3" classCode="OBS" moodCode="EVN">
<templateId root="2.16.840.1.113883.10.20.15.3.1"/>
<code code="11778-8" codeSystem="2.16.840.1.113883.6.1" codeSystemName="LOINC"/>
<statusCode code="completed"/>
</observation>

0.010
testValidateEstimatedDateOfDeliveryClassCode

Constraint

Consol Estimated Date Of Delivery SHALL contain exactly one [1..1] @classCode="OBS" Observation (CodeSystem: 2.16.840.1.113883.5.6 HL7ActClass) (CONF:444)

OCL

self.classCode=vocab::ActClassObservation::OBS

SuccessInvalid XML


<observation xmlns="urn:hl7-org:v3"/>

Valid XML


<observation xmlns="urn:hl7-org:v3" classCode="OBS" moodCode="EVN">
<templateId root="2.16.840.1.113883.10.20.15.3.1"/>
<code code="11778-8" codeSystem="2.16.840.1.113883.6.1" codeSystemName="LOINC"/>
<statusCode code="completed"/>
</observation>

0.006
testValidateEstimatedDateOfDeliveryCode

Constraint

Consol Estimated Date Of Delivery SHALL contain exactly one [1..1] code/@code="11778-8" (CodeSystem: 2.16.840.1.113883.6.1 LOINC) (CONF:446)

OCL

(self.code.oclIsUndefined() or self.code.isNullFlavorUndefined()) implies (not self.code.oclIsUndefined() and self.code.oclIsKindOf(datatypes::CD) and let value : datatypes::CD = self.code.oclAsType(datatypes::CD) in value.code = '11778-8' and value.codeSystem = '2.16.840.1.113883.6.1')

SuccessInvalid XML


<observation xmlns="urn:hl7-org:v3"/>

Valid XML


<observation xmlns="urn:hl7-org:v3" classCode="OBS" moodCode="EVN">
<templateId root="2.16.840.1.113883.10.20.15.3.1"/>
<code code="11778-8" codeSystem="2.16.840.1.113883.6.1" codeSystemName="LOINC"/>
<statusCode code="completed"/>
</observation>

0.056
testValidateEstimatedDateOfDeliveryMoodCode

Constraint

Consol Estimated Date Of Delivery SHALL contain exactly one [1..1] @moodCode="EVN" Event (CodeSystem: 2.16.840.1.113883.5.1001 HL7ActMood) (CONF:445)

OCL

self.moodCode=vocab::x_ActMoodDocumentObservation::EVN

SuccessInvalid XML


<observation xmlns="urn:hl7-org:v3"/>

Valid XML


<observation xmlns="urn:hl7-org:v3" classCode="OBS" moodCode="EVN">
<templateId root="2.16.840.1.113883.10.20.15.3.1"/>
<code code="11778-8" codeSystem="2.16.840.1.113883.6.1" codeSystemName="LOINC"/>
<statusCode code="completed"/>
</observation>

0.006
testValidateEstimatedDateOfDeliveryStatusCode

Constraint

Consol Estimated Date Of Delivery SHALL contain exactly one [1..1] statusCode/@code="completed" (CodeSystem: 2.16.840.1.113883.5.14 ActStatus) (CONF:448)

OCL

(self.statusCode.oclIsUndefined() or self.statusCode.isNullFlavorUndefined()) implies (not self.statusCode.oclIsUndefined() and self.statusCode.oclIsKindOf(datatypes::CS) and let value : datatypes::CS = self.statusCode.oclAsType(datatypes::CS) in value.code = 'completed')

SuccessInvalid XML


<observation xmlns="urn:hl7-org:v3"/>

Valid XML


<observation xmlns="urn:hl7-org:v3" classCode="OBS" moodCode="EVN">
<templateId root="2.16.840.1.113883.10.20.15.3.1"/>
<code code="11778-8" codeSystem="2.16.840.1.113883.6.1" codeSystemName="LOINC"/>
<statusCode code="completed"/>
</observation>

0.058
testValidateEstimatedDateOfDeliveryValue

Constraint

Consol Estimated Date Of Delivery SHALL contain exactly one [1..1] value with data type TS (CONF:450)

OCL

(self.value->isEmpty() or self.value->exists(element | element.isNullFlavorUndefined())) implies (self.value->size() = 1 and self.value->forAll(element | element.oclIsTypeOf(datatypes::TS)))

SuccessInvalid XML


<observation xmlns="urn:hl7-org:v3"/>

Valid XML


<observation xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="urn:hl7-org:v3" classCode="OBS" moodCode="EVN">
<templateId root="2.16.840.1.113883.10.20.15.3.1"/>
<code code="11778-8" codeSystem="2.16.840.1.113883.6.1" codeSystemName="LOINC"/>
<statusCode code="completed"/>
<value xsi:type="TS"/>
</observation>

0.037
Properties »