Unit Test Results.

Designed for use with JUnit and Ant.

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

NameTestsErrorsFailuresTime(s)Time StampHost
AssessmentAndPlanSectionTest7000.1202013-01-31T13:34:40JKMSoftware-desktop

Tests

NameStatusResultTime(s)
testConstructor

Constraint

OCL

SuccessInvalid XML

Valid XML

0.001
testValidateAssessmentAndPlanSectionTemplateId

Constraint

SHALL contain exactly one [1..1] templateId ( CONF:7705, CONF:10381 ) such that it SHALL contain exactly one [1..1] @root="2.16.840.1.113883.10.20.22.2.9"

OCL

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

SuccessInvalid XML


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

Valid XML


<section xmlns="urn:hl7-org:v3">
<templateId root="2.16.840.1.113883.10.20.22.2.9"/>
<code code="51847-2" codeSystem="2.16.840.1.113883.6.1" codeSystemName="LOINC" displayName="ASSESSMENT AND PLAN"/>
</section>

0.008
testValidateAssessmentAndPlanSectionCode

Constraint

Consol Assessment And Plan Section SHALL contain exactly one [1..1] code (CONF:15353)/@code="51847-2" ASSESSMENT AND PLAN (CodeSystem: 2.16.840.1.113883.6.1 LOINC) (CONF:15354)

OCL

(self.code.oclIsUndefined() or self.code.isNullFlavorUndefined()) implies (not self.code.oclIsUndefined() and self.code.oclIsKindOf(datatypes::CE) and let value : datatypes::CE = self.code.oclAsType(datatypes::CE) in value.code = '51847-2' and value.codeSystem = '2.16.840.1.113883.6.1')

SuccessInvalid XML


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

Valid XML


<section xmlns="urn:hl7-org:v3">
<templateId root="2.16.840.1.113883.10.20.22.2.9"/>
<code code="51847-2" codeSystem="2.16.840.1.113883.6.1" codeSystemName="LOINC" displayName="ASSESSMENT AND PLAN"/>
</section>

0.045
testValidateAssessmentAndPlanSectionCodeP

Constraint

Consol Assessment And Plan Section SHALL contain exactly one [1..1] code (CONF:15353)/@code="51847-2" ASSESSMENT AND PLAN (CodeSystem: 2.16.840.1.113883.6.1 LOINC) (CONF:15354)

OCL

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

SuccessInvalid XML


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

Valid XML


<section xmlns="urn:hl7-org:v3">
<templateId root="2.16.840.1.113883.10.20.22.2.9"/>
<code code="51847-2" codeSystem="2.16.840.1.113883.6.1" codeSystemName="LOINC" displayName="ASSESSMENT AND PLAN"/>
</section>

0.020
testValidateAssessmentAndPlanSectionText

Constraint

Consol Assessment And Plan Section SHALL contain exactly one [1..1] text (CONF:7707)

OCL

not self.text.oclIsUndefined()

SuccessInvalid XML


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

Valid XML


<section xmlns="urn:hl7-org:v3">
<templateId root="2.16.840.1.113883.10.20.22.2.9"/>
<code code="51847-2" codeSystem="2.16.840.1.113883.6.1" codeSystemName="LOINC" displayName="ASSESSMENT AND PLAN"/>
<text/>
</section>

0.007
testValidateAssessmentAndPlanSectionPlanOfCareActivityAct

Constraint

Consol Assessment And Plan Section MAY contain zero or more [0..*] entry (CONF:8798) Contains exactly one [1..1] Plan Of Care Activity Act (templateId: 2.16.840.1.113883.10.20.22.4.39)

OCL

self.entry->exists(entry : cda::Entry | not entry.act.oclIsUndefined() and entry.act.oclIsKindOf(consol::PlanOfCareActivityAct))

SuccessInvalid XML


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

Valid XML


<section xmlns="urn:hl7-org:v3">
<templateId root="2.16.840.1.113883.10.20.22.2.9"/>
<code code="51847-2" codeSystem="2.16.840.1.113883.6.1" codeSystemName="LOINC" displayName="ASSESSMENT AND PLAN"/>
<entry>
<act/>
</entry>
</section>

0.017
testGetPlanOfCareActivityActs

Constraint

OCL

SuccessInvalid XML

Valid XML

0.018
Properties »