openEHR / adl2-core

ADL / AOM 2 (previously known as '1.5') core libs and parser
GNU Affero General Public License v3.0
6 stars 8 forks source link

OperationalTemplateBuilder fails #1

Closed bjornna closed 10 years ago

bjornna commented 10 years ago

Hi Thanks for the great project. I just started to look at it. I have done two things:

  1. Imported the project into a Jenkins build server on Linux. It worked fine
  2. Imported the project on my Windows laptop. One test failed.

The test that failed is: org.openehr.adl.flattener.OperationalTemplateBuilderTest#testOntologyMerge

The problem is that the order of ComponentOntologies is wrong. The original test is:

assertThat(template.getComponentOntologies().get(0).getArchetypeId()).isEqualTo("openEHR-EHR-COMPOSITION.root_use_archetype.v1");
assertThat(template.getComponentOntologies().get(1).getArchetypeId()).isEqualTo("openEHR-EHR-EVALUATION.alert.v1");

This failes. But if I change order (like below) the test is ok:

assertThat(template.getComponentOntologies().get(1).getArchetypeId()).isEqualTo("openEHR-EHR-COMPOSITION.root_use_archetype.v1");
assertThat(template.getComponentOntologies().get(0).getArchetypeId()).isEqualTo("openEHR-EHR-EVALUATION.alert.v1");

I will do some more testing to see how this happens.

PS! The laptop it fails on is Windows 7 and my JDK is :

Bjørn