Search in sources :

Example 11 with Diff

use of org.javers.core.diff.Diff in project fhir-bridge by ehrbase.

the class PregnancyStatusIT method testMapping.

@Override
public void testMapping(String resourcePath, String paragonPath) throws IOException {
    Observation observation = (Observation) super.testFileLoader.loadResource(resourcePath);
    PregnancyStatusCompositionConverter pregnancyStatusCompositionConverter = new PregnancyStatusCompositionConverter();
    SchwangerschaftsstatusComposition mapped = pregnancyStatusCompositionConverter.convert(observation);
    Diff diff = compareCompositions(getJavers(), paragonPath, mapped);
    assertEquals(0, diff.getChanges().size());
}
Also used : Diff(org.javers.core.diff.Diff) PregnancyStatusCompositionConverter(org.ehrbase.fhirbridge.ehr.converter.specific.pregnancystatus.PregnancyStatusCompositionConverter) SchwangerschaftsstatusObservation(org.ehrbase.fhirbridge.ehr.opt.schwangerschaftsstatuscomposition.definition.SchwangerschaftsstatusObservation) Observation(org.hl7.fhir.r4.model.Observation) SchwangerschaftsstatusComposition(org.ehrbase.fhirbridge.ehr.opt.schwangerschaftsstatuscomposition.SchwangerschaftsstatusComposition)

Example 12 with Diff

use of org.javers.core.diff.Diff in project fhir-bridge by ehrbase.

the class RespirationRateIT method testMapping.

@Override
public void testMapping(String resourcePath, String paragonPath) throws IOException {
    Observation observation = (Observation) super.testFileLoader.loadResource(resourcePath);
    RespiratoryRateCompositionConverter respiratoryRateCompositionConverter = new RespiratoryRateCompositionConverter();
    AtemfrequenzComposition mapped = respiratoryRateCompositionConverter.convert(observation);
    Diff diff = compareCompositions(getJavers(), paragonPath, mapped);
    assertEquals(0, diff.getChanges().size());
}
Also used : AtemfrequenzComposition(org.ehrbase.fhirbridge.ehr.opt.atemfrequenzcomposition.AtemfrequenzComposition) RespiratoryRateCompositionConverter(org.ehrbase.fhirbridge.ehr.converter.specific.respirationrate.RespiratoryRateCompositionConverter) Diff(org.javers.core.diff.Diff) AtemfrequenzObservation(org.ehrbase.fhirbridge.ehr.opt.atemfrequenzcomposition.definition.AtemfrequenzObservation) Observation(org.hl7.fhir.r4.model.Observation)

Example 13 with Diff

use of org.javers.core.diff.Diff in project fhir-bridge by ehrbase.

the class BloodPressureIT method testMapping.

@Override
public void testMapping(String resourcePath, String paragonPath) throws IOException {
    Observation observation = (Observation) super.testFileLoader.loadResource(resourcePath);
    BloodPressureCompositionConverter compositionConverter = new BloodPressureCompositionConverter();
    BlutdruckComposition mapped = compositionConverter.convert(observation);
    Diff diff = compareCompositions(getJavers(), paragonPath, mapped);
    assertEquals(0, diff.getChanges().size());
}
Also used : BlutdruckComposition(org.ehrbase.fhirbridge.ehr.opt.blutdruckcomposition.BlutdruckComposition) Diff(org.javers.core.diff.Diff) BlutdruckObservation(org.ehrbase.fhirbridge.ehr.opt.blutdruckcomposition.definition.BlutdruckObservation) Observation(org.hl7.fhir.r4.model.Observation) BloodPressureCompositionConverter(org.ehrbase.fhirbridge.ehr.converter.specific.bloodpressure.BloodPressureCompositionConverter)

Example 14 with Diff

use of org.javers.core.diff.Diff in project fhir-bridge by ehrbase.

the class BodyHeightIT method testMapping.

@Override
public void testMapping(String resourcePath, String paragonPath) throws IOException {
    Observation observation = (Observation) super.testFileLoader.loadResource(resourcePath);
    BodyHeightCompositionConverter bodyHeightCompositionConverter = new BodyHeightCompositionConverter();
    KoerpergroesseComposition mapped = bodyHeightCompositionConverter.convert(observation);
    Diff diff = compareCompositions(getJavers(), paragonPath, mapped);
    assertEquals(0, diff.getChanges().size());
}
Also used : Diff(org.javers.core.diff.Diff) BodyHeightCompositionConverter(org.ehrbase.fhirbridge.ehr.converter.specific.bodyheight.BodyHeightCompositionConverter) GroesseLaengeObservation(org.ehrbase.fhirbridge.ehr.opt.koerpergroessecomposition.definition.GroesseLaengeObservation) Observation(org.hl7.fhir.r4.model.Observation) KoerpergroesseComposition(org.ehrbase.fhirbridge.ehr.opt.koerpergroessecomposition.KoerpergroesseComposition)

Example 15 with Diff

use of org.javers.core.diff.Diff in project fhir-bridge by ehrbase.

the class BodyTemperatureIT method testMapping.

@Override
public void testMapping(String resourcePath, String paragonPath) throws IOException {
    Observation observation = (Observation) super.testFileLoader.loadResource(resourcePath);
    KoerpertemperaturCompositionConverter bodyTemperatureCompositionConverter = new KoerpertemperaturCompositionConverter();
    KoerpertemperaturComposition mapped = bodyTemperatureCompositionConverter.convert(observation);
    Diff diff = compareCompositions(getJavers(), paragonPath, mapped);
    assertEquals(0, diff.getChanges().size());
}
Also used : KoerpertemperaturCompositionConverter(org.ehrbase.fhirbridge.ehr.converter.specific.bodytemperature.KoerpertemperaturCompositionConverter) Diff(org.javers.core.diff.Diff) KoerpertemperaturComposition(org.ehrbase.fhirbridge.ehr.opt.koerpertemperaturcomposition.KoerpertemperaturComposition) KoerpertemperaturObservation(org.ehrbase.fhirbridge.ehr.opt.koerpertemperaturcomposition.definition.KoerpertemperaturObservation) Observation(org.hl7.fhir.r4.model.Observation)

Aggregations

Diff (org.javers.core.diff.Diff)57 Observation (org.hl7.fhir.r4.model.Observation)23 Javers (org.javers.core.Javers)10 Test (org.junit.Test)5 Bundle (org.hl7.fhir.r4.model.Bundle)4 DualProtocolSaajSoapMessageFactory (ca.bc.gov.open.pcss.civil.comparison.config.DualProtocolSaajSoapMessageFactory)2 List (java.util.List)2 UsernamePasswordCredentials (org.apache.http.auth.UsernamePasswordCredentials)2 VirologischerBefundCompositionConverter (org.ehrbase.fhirbridge.ehr.converter.specific.virologischerbefund.VirologischerBefundCompositionConverter)2 GECCOPersonendatenComposition (org.ehrbase.fhirbridge.ehr.opt.geccopersonendatencomposition.GECCOPersonendatenComposition)2 VirologischerBefundComposition (org.ehrbase.fhirbridge.ehr.opt.virologischerbefundcomposition.VirologischerBefundComposition)2 BefundObservation (org.ehrbase.fhirbridge.ehr.opt.virologischerbefundcomposition.definition.BefundObservation)2 VirologischerBefundConverter (org.ehrbase.fhirbridge.fhir.bundle.converter.VirologischerBefundConverter)2 Condition (org.hl7.fhir.r4.model.Condition)2 DiagnosticReport (org.hl7.fhir.r4.model.DiagnosticReport)2 ValueChange (org.javers.core.diff.changetype.ValueChange)2 WebServiceSenderWithAuth (ca.bc.gov.open.pcss.civil.comparison.config.WebServiceSenderWithAuth)1 ca.bc.gov.open.pcss.three (ca.bc.gov.open.pcss.three)1 YesNoType (ca.bc.gov.open.pcss.two.YesNoType)1 VisibleForTesting (com.google.common.annotations.VisibleForTesting)1