Unit Test Results.

Designed for use with JUnit and Ant.

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

NameTestsErrorsFailuresTime(s)Time StampHost
CognitiveStatusResultOrganizerTest11000.2072013-01-31T13:34:44JKMSoftware-desktop

Tests

NameStatusResultTime(s)
testConstructor

Constraint

OCL

SuccessInvalid XML

Valid XML

0.000
testValidateResultOrganizerTemplateId

Constraint

The 'ResultOrganizerTemplateId' invariant is violated on 'org.openhealthtools.mdht.uml.cda.mu2consol.impl.ResultOrganizerImpl@258b0bc{#//}'

OCL

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

SuccessInvalid XML


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

Valid XML


<organizer xmlns="urn:hl7-org:v3" moodCode="EVN">
<templateId root="2.16.840.1.113883.10.20.22.4.1"/>
<templateId root="2.16.840.1.113883.10.20.22.4.1"/>
</organizer>

0.010
testValidateCognitiveStatusResultOrganizerCodeCodeSystem

Constraint

Consol Cognitive Status Result Organizer code SHOULD contain zero or one [0..1] @code should be selected from ICF (codeSystem 2.16.840.1.113883.6.254) or SNOMED CT (codeSystem 2.16.840.1.113883.6.96) (CONF:14697, CONF:14698)

OCL

self.code.isNullFlavorDefined() or self.code.codeSystem = '2.16.840.1.113883.6.254' or self.code.codeSystem = '2.16.840.1.113883.6.96'

SuccessInvalid XML


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

Valid XML


<organizer xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="urn:hl7-org:v3" classCode="CLUSTER" moodCode="EVN">
<templateId root="2.16.840.1.113883.10.20.22.4.75"/>
<templateId root="2.16.840.1.113883.10.20.22.4.1"/>
<code xsi:type="CE" code="" codeSystem="2.16.840.1.113883.6.96"/>
<statusCode code="completed"/>
</organizer>

0.023
testValidateCognitiveStatusResultOrganizerClassCode

Constraint

Consol Cognitive Status Result Organizer SHALL contain exactly one [1..1] @classCode="CLUSTER" (CodeSystem: 2.16.840.1.113883.5.6 HL7ActClass) (CONF:14369)

OCL

self.classCode=vocab::x_ActClassDocumentEntryOrganizer::CLUSTER

SuccessInvalid XML


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

Valid XML


<organizer xmlns="urn:hl7-org:v3" classCode="CLUSTER" moodCode="EVN">
<templateId root="2.16.840.1.113883.10.20.22.4.75"/>
<templateId root="2.16.840.1.113883.10.20.22.4.1"/>
<statusCode code="completed"/>
</organizer>

0.006
testValidateCognitiveStatusResultOrganizerMoodCode

Constraint

Consol Cognitive Status Result Organizer SHALL contain exactly one [1..1] @moodCode="EVN" Event (CodeSystem: 2.16.840.1.113883.5.1001 HL7ActMood) (CONF:14371)

OCL

self.moodCode=vocab::ActMood::EVN

SuccessInvalid XML


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

Valid XML


<organizer xmlns="urn:hl7-org:v3" classCode="CLUSTER" moodCode="EVN">
<templateId root="2.16.840.1.113883.10.20.22.4.75"/>
<templateId root="2.16.840.1.113883.10.20.22.4.1"/>
<statusCode code="completed"/>
</organizer>

0.006
testValidateCognitiveStatusResultOrganizerId

Constraint

Consol Cognitive Status Result Organizer SHALL contain at least one [1..*] id (CONF:14377)

OCL

(self.id->isEmpty() or self.id->exists(element | element.isNullFlavorUndefined())) implies (not self.id->isEmpty())

SuccessInvalid XML


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

Valid XML


<organizer xmlns="urn:hl7-org:v3" classCode="CLUSTER" moodCode="EVN">
<templateId root="2.16.840.1.113883.10.20.22.4.75"/>
<templateId root="2.16.840.1.113883.10.20.22.4.1"/>
<id/>
<statusCode code="completed"/>
</organizer>

0.024
testValidateCognitiveStatusResultOrganizerCode

Constraint

Consol Cognitive Status Result Organizer SHALL contain exactly one [1..1] code (CONF:14378)

OCL

(self.code.oclIsUndefined() or self.code.isNullFlavorUndefined()) implies (not self.code.oclIsUndefined())

SuccessInvalid XML


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

Valid XML


<organizer xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="urn:hl7-org:v3" classCode="CLUSTER" moodCode="EVN">
<templateId root="2.16.840.1.113883.10.20.22.4.75"/>
<templateId root="2.16.840.1.113883.10.20.22.4.1"/>
<code xsi:type="CE"/>
<statusCode code="completed"/>
</organizer>

0.021
testValidateCognitiveStatusResultOrganizerStatusCodeP

Constraint

Consol Cognitive Status Result Organizer SHALL contain exactly one [1..1] statusCode (CONF:14372)/@code="completed" Completed (CodeSystem: 2.16.840.1.113883.5.14 ActStatus)

OCL

(self.statusCode.oclIsUndefined() or self.statusCode.isNullFlavorUndefined()) implies (not self.statusCode.oclIsUndefined())

SuccessInvalid XML


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

Valid XML


<organizer xmlns="urn:hl7-org:v3" classCode="CLUSTER" moodCode="EVN">
<templateId root="2.16.840.1.113883.10.20.22.4.75"/>
<templateId root="2.16.840.1.113883.10.20.22.4.1"/>
<statusCode code="completed"/>
</organizer>

0.026
testValidateCognitiveStatusResultOrganizerStatusCode

Constraint

Consol Cognitive Status Result Organizer SHALL contain exactly one [1..1] statusCode (CONF:14372)/@code="completed" Completed (CodeSystem: 2.16.840.1.113883.5.14 ActStatus)

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


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

Valid XML


<organizer xmlns="urn:hl7-org:v3" classCode="CLUSTER" moodCode="EVN">
<templateId root="2.16.840.1.113883.10.20.22.4.75"/>
<templateId root="2.16.840.1.113883.10.20.22.4.1"/>
<statusCode code="completed"/>
</organizer>

0.048
testValidateCognitiveStatusResultOrganizerCognitiveStatusResultObservation

Constraint

Consol Cognitive Status Result Organizer SHALL contain at least one [1..*] component (CONF:14373, CONF:14381) Contains exactly one [1..1] Cognitive Status Result Observation (templateId: 2.16.840.1.113883.10.20.22.4.74)

OCL

self.component->exists(component : cda::Component4 | not component.observation.oclIsUndefined() and component.observation.oclIsKindOf(consol::CognitiveStatusResultObservation))

SuccessInvalid XML


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

Valid XML


<organizer xmlns="urn:hl7-org:v3" classCode="CLUSTER" moodCode="EVN">
<templateId root="2.16.840.1.113883.10.20.22.4.75"/>
<templateId root="2.16.840.1.113883.10.20.22.4.1"/>
<statusCode code="completed"/>
<component>
<observation/>
</component>
</organizer>

0.019
testGetCognitiveStatusResultObservations

Constraint

OCL

SuccessInvalid XML

Valid XML

0.021
Properties »