From bf30551b09dd1202092a4e45468fcaea9049dcbb Mon Sep 17 00:00:00 2001 From: chgl Date: Wed, 8 Nov 2023 12:18:38 +0100 Subject: [PATCH] test: finalized snapshot testing implementation --- .gitignore | 2 + README.md | 28 +- src/main/resources/application.yml | 2 +- .../processor/ObdsConditionProcessorTest.java | 43 +- .../ObdsMedicationStatementProcessorTest.java | 41 +- .../ObdsObservationProcessorTest.java | 43 +- .../processor/ObdsProcedureProcessorTest.java | 35 +- .../processor/ObdsProcessorTest.java | 47 ++ ...ernMetaausDIAGNOSE.xml.approved.fhir.json" | 96 +++ ..._TumorID_1_Diagnose.xml.approved.fhir.json | 91 +++ ..._TumorID_2_Diagnose.xml.approved.fhir.json | 60 ++ ...ehandlungsende_SYST.xml.approved.fhir.json | 340 +++++++++ ...dlungsende_SYST.xml.received.approved.json | 340 +++++++++ ...010_Pat2_Tumor1_Tod.xml.approved.fhir.json | 677 ++++++++++++++++++ ..._TumorID_1_Diagnose.xml.approved.fhir.json | 581 +++++++++++++++ ..._Behandlungsende_OP.xml.approved.fhir.json | 2 +- ..._Behandlungsende_ST.xml.approved.fhir.json | 2 +- 17 files changed, 2296 insertions(+), 134 deletions(-) create mode 100644 "src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsConditionProcessorTest.mapCondition_withGivenAdtXml.001_1.Pat_2Tumoren_TumorID_1_Diagnose.xml.003_Pat1_Tumor1_Therapie1_Behandlungsende_OP.xml.009_Pat1_Tumor1_Statusaenderung_Fernmeta_3x-\303\274berschreibt2xFernMetaausDIAGNOSE.xml.approved.fhir.json" create mode 100644 src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsConditionProcessorTest.mapCondition_withGivenAdtXml.001_1.Pat_2Tumoren_TumorID_1_Diagnose.xml.approved.fhir.json create mode 100644 src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsConditionProcessorTest.mapCondition_withGivenAdtXml.002_1.Pat_2Tumoren_TumorID_2_Diagnose.xml.approved.fhir.json create mode 100644 src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsMedicationStatementProcessorTest.mapMedicationStatement_withGivenAdtXml.008_Pat3_Tumor1_Behandlungsende_SYST.xml.approved.fhir.json create mode 100644 src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsMedicationStatementProcessorTest.mapMedicationStatement_withGivenAdtXml.008_Pat3_Tumor1_Behandlungsende_SYST.xml.received.approved.json create mode 100644 src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsObservationProcessorTest.mapObservation_withGivenAdtXml.001_1.Pat_2Tumoren_TumorID_1_Diagnose.xml.003_Pat1_Tumor1_Therapie1_Behandlungsende_OP.xml.010_Pat2_Tumor1_Tod.xml.approved.fhir.json create mode 100644 src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsObservationProcessorTest.mapObservation_withGivenAdtXml.001_1.Pat_2Tumoren_TumorID_1_Diagnose.xml.approved.fhir.json diff --git a/.gitignore b/.gitignore index 202756cc..dc79945d 100644 --- a/.gitignore +++ b/.gitignore @@ -57,3 +57,5 @@ bin # ignored since it isn't automatically refreshed by renovate # (we're also pinning the dependency versions anyways) fhirpkg.lock.json + +*.received.fhir.json diff --git a/README.md b/README.md index 701b3fe9..dd5ec1da 100644 --- a/README.md +++ b/README.md @@ -4,7 +4,33 @@ This project contains a Kafka Stream processor that creates FHIR resources from ## Used FHIR profiles -See [package.json](package.json) for a list of used profiles and their versions. +See [package.json](package.json) for a list of used packages and their versions. + +## Observations + +- Histologie () +- Grading () +- TNMc () +- TNMp () +- Fernmetastasen () +- Tod Ursache () + +## Condition + +- Primärdiagnose () + +## Procedure + +- Operation () +- Strahlentherapie () + +## MedicationStatement + +- Systemtherapie () + +## Patient + +- Patient () ## Dev diff --git a/src/main/resources/application.yml b/src/main/resources/application.yml index c3f02f7e..a2de98bb 100644 --- a/src/main/resources/application.yml +++ b/src/main/resources/application.yml @@ -18,7 +18,7 @@ fhir: observationId: "https://fhir.diz.uk-erlangen.de/identifiers/onkostar-xml-observation-id" procedureId: "https://fhir.diz.uk-erlangen.de/identifiers/onkostar-xml-procedure-id" medicationStatementId: "https://fhir.diz.uk-erlangen.de/identifiers/onkostar-xml-medication-statement-id" - observationCategorySystem: "http://terminology.hl7.org/CodeSystem/observation-category" + observationCategorySystem: "http://hl7.org/fhir/observation-category" loinc: "http://loinc.org" idco3Morphologie: "urn:oid:2.16.840.1.113883.6.43.1" gradingDktk: "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/GradingCS" diff --git a/src/test/java/org/miracum/streams/ume/obdstofhir/processor/ObdsConditionProcessorTest.java b/src/test/java/org/miracum/streams/ume/obdstofhir/processor/ObdsConditionProcessorTest.java index 6133fa51..f8e7689e 100644 --- a/src/test/java/org/miracum/streams/ume/obdstofhir/processor/ObdsConditionProcessorTest.java +++ b/src/test/java/org/miracum/streams/ume/obdstofhir/processor/ObdsConditionProcessorTest.java @@ -2,30 +2,24 @@ import static org.assertj.core.api.Assertions.assertThat; -import ca.uhn.fhir.context.FhirContext; import ca.uhn.fhir.util.BundleUtil; -import java.io.File; import java.io.IOException; -import java.nio.file.Files; import java.util.*; import java.util.stream.Stream; -import org.apache.commons.lang3.StringUtils; import org.apache.commons.lang3.tuple.Pair; +import org.approvaltests.Approvals; import org.hl7.fhir.r4.model.Condition; import org.junit.jupiter.params.ParameterizedTest; import org.junit.jupiter.params.provider.Arguments; import org.junit.jupiter.params.provider.MethodSource; import org.miracum.streams.ume.obdstofhir.FhirProperties; import org.miracum.streams.ume.obdstofhir.mapper.*; -import org.miracum.streams.ume.obdstofhir.model.MeldungExport; -import org.miracum.streams.ume.obdstofhir.model.MeldungExportList; import org.miracum.streams.ume.obdstofhir.model.Tupel; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.boot.context.properties.EnableConfigurationProperties; import org.springframework.boot.test.context.SpringBootTest; -import org.springframework.util.ResourceUtils; @SpringBootTest( classes = { @@ -48,7 +42,6 @@ public class ObdsConditionProcessorTest extends ObdsProcessorTest { private final ObdsProcedureMapper onkoProcedureMapper; private final ObdsPatientMapper onkoPatientMapper; private final ObdsConditionMapper onkoConditionMapper; - private final FhirContext ctx = FhirContext.forR4(); @Autowired public ObdsConditionProcessorTest( @@ -123,31 +116,7 @@ void mapCondition_withGivenAdtXml( String expectedOnsetDate) throws IOException { - MeldungExportList meldungExportList = new MeldungExportList(); - - int payloadId = 1; - - for (var xmlTupel : xmlFileNames) { - File xmlFile = ResourceUtils.getFile("classpath:" + xmlTupel.getFirst()); - String xmlContent = new String(Files.readAllBytes(xmlFile.toPath())); - - var meldungsId = StringUtils.substringBetween(xmlContent, "Meldung_ID=\"", "\" Melder_ID"); - var melderId = StringUtils.substringBetween(xmlContent, "Melder_ID=\"", "\">"); - var patId = StringUtils.substringBetween(xmlContent, "Patient_ID=\"", "\">"); - - Map payloadOnkoRessource = new HashMap<>(); - payloadOnkoRessource.put("ID", payloadId); - payloadOnkoRessource.put("REFERENZ_NUMMER", patId); - payloadOnkoRessource.put("LKR_MELDUNG", Integer.parseInt(meldungsId.replace(melderId, ""))); - payloadOnkoRessource.put("VERSIONSNUMMER", xmlTupel.getSecond()); - payloadOnkoRessource.put("XML_DATEN", xmlContent); - - MeldungExport meldungExport = new MeldungExport(); - meldungExport.getPayload(payloadOnkoRessource); - meldungExportList.addElement(meldungExport); - - payloadId++; - } + var meldungExportList = buildMeldungExportList(xmlFileNames); ObdsProcessor onkoProcessor = new ObdsProcessor( @@ -192,7 +161,13 @@ void mapCondition_withGivenAdtXml( assertThat(conditionList.get(0).getOnsetDateTimeType().getValueAsString()) .isEqualTo(expectedOnsetDate); - // assertThat(isValid(resultBundle)).isTrue(); + var fhirJson = fhirParser.encodeResourceToString(resultBundle); + Approvals.verify( + fhirJson, + Approvals.NAMES + .withParameters(xmlFileNames.stream().map(t -> t.getFirst()).toArray(String[]::new)) + .forFile() + .withExtension(".fhir.json")); } } } diff --git a/src/test/java/org/miracum/streams/ume/obdstofhir/processor/ObdsMedicationStatementProcessorTest.java b/src/test/java/org/miracum/streams/ume/obdstofhir/processor/ObdsMedicationStatementProcessorTest.java index a7d7cf9e..9cc0a9b2 100644 --- a/src/test/java/org/miracum/streams/ume/obdstofhir/processor/ObdsMedicationStatementProcessorTest.java +++ b/src/test/java/org/miracum/streams/ume/obdstofhir/processor/ObdsMedicationStatementProcessorTest.java @@ -4,12 +4,10 @@ import ca.uhn.fhir.context.FhirContext; import ca.uhn.fhir.util.BundleUtil; -import java.io.File; import java.io.IOException; -import java.nio.file.Files; import java.util.*; import java.util.stream.Stream; -import org.apache.commons.lang3.StringUtils; +import org.approvaltests.Approvals; import org.hl7.fhir.r4.model.CodeableConcept; import org.hl7.fhir.r4.model.MedicationStatement; import org.junit.jupiter.params.ParameterizedTest; @@ -17,15 +15,12 @@ import org.junit.jupiter.params.provider.MethodSource; import org.miracum.streams.ume.obdstofhir.FhirProperties; import org.miracum.streams.ume.obdstofhir.mapper.*; -import org.miracum.streams.ume.obdstofhir.model.MeldungExport; -import org.miracum.streams.ume.obdstofhir.model.MeldungExportList; import org.miracum.streams.ume.obdstofhir.model.Tupel; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.boot.context.properties.EnableConfigurationProperties; import org.springframework.boot.test.context.SpringBootTest; -import org.springframework.util.ResourceUtils; @SpringBootTest( classes = { @@ -101,31 +96,7 @@ void mapMedicationStatement_withGivenAdtXml( String expectedIntention) throws IOException { - MeldungExportList meldungExportList = new MeldungExportList(); - - int payloadId = 1; - - for (var xmlTupel : xmlFileNames) { - File xmlFile = ResourceUtils.getFile("classpath:" + xmlTupel.getFirst()); - String xmlContent = new String(Files.readAllBytes(xmlFile.toPath())); - - var meldungsId = StringUtils.substringBetween(xmlContent, "Meldung_ID=\"", "\" Melder_ID"); - var melderId = StringUtils.substringBetween(xmlContent, "Melder_ID=\"", "\">"); - var patId = StringUtils.substringBetween(xmlContent, "Patient_ID=\"", "\">"); - - Map payloadOnkoRessource = new HashMap<>(); - payloadOnkoRessource.put("ID", payloadId); - payloadOnkoRessource.put("REFERENZ_NUMMER", patId); - payloadOnkoRessource.put("LKR_MELDUNG", Integer.parseInt(meldungsId.replace(melderId, ""))); - payloadOnkoRessource.put("VERSIONSNUMMER", xmlTupel.getSecond()); - payloadOnkoRessource.put("XML_DATEN", xmlContent); - - MeldungExport meldungExport = new MeldungExport(); - meldungExport.getPayload(payloadOnkoRessource); - meldungExportList.addElement(meldungExport); - - payloadId++; - } + var meldungExportList = buildMeldungExportList(xmlFileNames); ObdsProcessor medicationStatementProcessor = new ObdsProcessor( @@ -186,7 +157,13 @@ void mapMedicationStatement_withGivenAdtXml( String finalPartOfId = partOfId; assertThat(partOfReferences).allSatisfy(ref -> ref.equals(finalPartOfId)); - // assertThat(isValid(resultBundle)).isTrue(); + var fhirJson = fhirParser.encodeResourceToString(resultBundle); + Approvals.verify( + fhirJson, + Approvals.NAMES + .withParameters(xmlFileNames.stream().map(t -> t.getFirst()).toArray(String[]::new)) + .forFile() + .withExtension(".fhir.json")); } } } diff --git a/src/test/java/org/miracum/streams/ume/obdstofhir/processor/ObdsObservationProcessorTest.java b/src/test/java/org/miracum/streams/ume/obdstofhir/processor/ObdsObservationProcessorTest.java index 08385601..cda5855b 100644 --- a/src/test/java/org/miracum/streams/ume/obdstofhir/processor/ObdsObservationProcessorTest.java +++ b/src/test/java/org/miracum/streams/ume/obdstofhir/processor/ObdsObservationProcessorTest.java @@ -2,14 +2,11 @@ import static org.assertj.core.api.Assertions.assertThat; -import ca.uhn.fhir.context.FhirContext; import ca.uhn.fhir.util.BundleUtil; -import java.io.File; import java.io.IOException; -import java.nio.file.Files; import java.util.*; import java.util.stream.Stream; -import org.apache.commons.lang3.StringUtils; +import org.approvaltests.Approvals; import org.hl7.fhir.r4.model.CodeableConcept; import org.hl7.fhir.r4.model.Observation; import org.junit.jupiter.params.ParameterizedTest; @@ -17,15 +14,12 @@ import org.junit.jupiter.params.provider.MethodSource; import org.miracum.streams.ume.obdstofhir.FhirProperties; import org.miracum.streams.ume.obdstofhir.mapper.*; -import org.miracum.streams.ume.obdstofhir.model.MeldungExport; -import org.miracum.streams.ume.obdstofhir.model.MeldungExportList; import org.miracum.streams.ume.obdstofhir.model.Tupel; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.boot.context.properties.EnableConfigurationProperties; import org.springframework.boot.test.context.SpringBootTest; -import org.springframework.util.ResourceUtils; @SpringBootTest( classes = { @@ -48,7 +42,6 @@ public class ObdsObservationProcessorTest extends ObdsProcessorTest { private final ObdsProcedureMapper onkoProcedureMapper; private final ObdsPatientMapper onkoPatientMapper; private final ObdsConditionMapper onkoConditionMapper; - private final FhirContext ctx = FhirContext.forR4(); @Autowired public ObdsObservationProcessorTest( @@ -110,31 +103,7 @@ void mapObservation_withGivenAdtXml( String expectedDeathDate) throws IOException { - MeldungExportList meldungExportList = new MeldungExportList(); - - int payloadId = 1; - - for (var xmlTupel : xmlFileNames) { - File xmlFile = ResourceUtils.getFile("classpath:" + xmlTupel.getFirst()); - String xmlContent = new String(Files.readAllBytes(xmlFile.toPath())); - - var meldungsId = StringUtils.substringBetween(xmlContent, "Meldung_ID=\"", "\" Melder_ID"); - var melderId = StringUtils.substringBetween(xmlContent, "Melder_ID=\"", "\">"); - var patId = StringUtils.substringBetween(xmlContent, "Patient_ID=\"", "\">"); - - Map payloadOnkoRessource = new HashMap<>(); - payloadOnkoRessource.put("ID", payloadId); - payloadOnkoRessource.put("REFERENZ_NUMMER", patId); - payloadOnkoRessource.put("LKR_MELDUNG", Integer.parseInt(meldungsId.replace(melderId, ""))); - payloadOnkoRessource.put("VERSIONSNUMMER", xmlTupel.getSecond()); - payloadOnkoRessource.put("XML_DATEN", xmlContent); - - MeldungExport meldungExport = new MeldungExport(); - meldungExport.getPayload(payloadOnkoRessource); - meldungExportList.addElement(meldungExport); - - payloadId++; - } + var meldungExportList = buildMeldungExportList(xmlFileNames); ObdsProcessor observationProcessor = new ObdsProcessor( @@ -226,7 +195,13 @@ void mapObservation_withGivenAdtXml( } assertThat(fenMetaCount).isEqualTo(expectedFernMetaCount); - // assertThat(isValid(resultBundle)).isTrue(); + var fhirJson = fhirParser.encodeResourceToString(resultBundle); + Approvals.verify( + fhirJson, + Approvals.NAMES + .withParameters(xmlFileNames.stream().map(t -> t.getFirst()).toArray(String[]::new)) + .forFile() + .withExtension(".fhir.json")); } } } diff --git a/src/test/java/org/miracum/streams/ume/obdstofhir/processor/ObdsProcedureProcessorTest.java b/src/test/java/org/miracum/streams/ume/obdstofhir/processor/ObdsProcedureProcessorTest.java index ee05431a..79f737fe 100644 --- a/src/test/java/org/miracum/streams/ume/obdstofhir/processor/ObdsProcedureProcessorTest.java +++ b/src/test/java/org/miracum/streams/ume/obdstofhir/processor/ObdsProcedureProcessorTest.java @@ -4,12 +4,9 @@ import ca.uhn.fhir.context.FhirContext; import ca.uhn.fhir.util.BundleUtil; -import java.io.File; import java.io.IOException; -import java.nio.file.Files; import java.util.*; import java.util.stream.Stream; -import org.apache.commons.lang3.StringUtils; import org.approvaltests.Approvals; import org.hl7.fhir.r4.model.CodeableConcept; import org.hl7.fhir.r4.model.Procedure; @@ -18,15 +15,12 @@ import org.junit.jupiter.params.provider.MethodSource; import org.miracum.streams.ume.obdstofhir.FhirProperties; import org.miracum.streams.ume.obdstofhir.mapper.*; -import org.miracum.streams.ume.obdstofhir.model.MeldungExport; -import org.miracum.streams.ume.obdstofhir.model.MeldungExportList; import org.miracum.streams.ume.obdstofhir.model.Tupel; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.boot.context.properties.EnableConfigurationProperties; import org.springframework.boot.test.context.SpringBootTest; -import org.springframework.util.ResourceUtils; @SpringBootTest( classes = { @@ -70,7 +64,7 @@ public ObdsProcedureProcessorTest( private static Stream generateTestData() { return Stream.of( Arguments.of( - new Tupel<>("003_Pat1_Tumor1_Therapie1_Behandlungsende_OP.xml", 1), + List.of(new Tupel<>("003_Pat1_Tumor1_Therapie1_Behandlungsende_OP.xml", 1)), 9, 9, 0, @@ -82,7 +76,7 @@ private static Stream generateTestData() { "N", "Nein"), Arguments.of( - new Tupel<>("007_Pat2_Tumor1_Behandlungsende_ST.xml", 1), + List.of(new Tupel<>("007_Pat2_Tumor1_Behandlungsende_ST.xml", 1)), 3, 0, 3, @@ -98,7 +92,7 @@ private static Stream generateTestData() { @ParameterizedTest @MethodSource("generateTestData") void mapProcedure_withGivenAdtXml( - Tupel xmlTupel, + List> xmlFileNames, int expectedProcCount, int expectedProcCountOp, int expectedProcCountSt, @@ -111,25 +105,7 @@ void mapProcedure_withGivenAdtXml( String expectedcomplicationDisplay) throws IOException { - MeldungExportList meldungExportList = new MeldungExportList(); - - File xmlFile = ResourceUtils.getFile("classpath:" + xmlTupel.getFirst()); - String xmlContent = new String(Files.readAllBytes(xmlFile.toPath())); - - var meldungsId = StringUtils.substringBetween(xmlContent, "Meldung_ID=\"", "\" Melder_ID"); - var melderId = StringUtils.substringBetween(xmlContent, "Melder_ID=\"", "\">"); - var patId = StringUtils.substringBetween(xmlContent, "Patient_ID=\"", "\">"); - - Map payloadOnkoRessource = new HashMap<>(); - payloadOnkoRessource.put("ID", 1); - payloadOnkoRessource.put("REFERENZ_NUMMER", patId); - payloadOnkoRessource.put("LKR_MELDUNG", Integer.parseInt(meldungsId.replace(melderId, ""))); - payloadOnkoRessource.put("VERSIONSNUMMER", xmlTupel.getSecond()); - payloadOnkoRessource.put("XML_DATEN", xmlContent); - - MeldungExport meldungExport = new MeldungExport(); - meldungExport.getPayload(payloadOnkoRessource); - meldungExportList.addElement(meldungExport); + var meldungExportList = buildMeldungExportList(xmlFileNames); ObdsProcessor procedureProcessor = new ObdsProcessor( @@ -227,12 +203,11 @@ void mapProcedure_withGivenAdtXml( assertThat(partOfReferences).allSatisfy(ref -> ref.equals(finalPartOfId)); } - var fhirParser = ctx.newJsonParser().setPrettyPrint(true); var fhirJson = fhirParser.encodeResourceToString(resultBundle); Approvals.verify( fhirJson, Approvals.NAMES - .withParameters(xmlTupel.getFirst()) + .withParameters(xmlFileNames.stream().map(t -> t.getFirst()).toArray(String[]::new)) .forFile() .withExtension(".fhir.json")); } diff --git a/src/test/java/org/miracum/streams/ume/obdstofhir/processor/ObdsProcessorTest.java b/src/test/java/org/miracum/streams/ume/obdstofhir/processor/ObdsProcessorTest.java index 98375075..f2aefd60 100644 --- a/src/test/java/org/miracum/streams/ume/obdstofhir/processor/ObdsProcessorTest.java +++ b/src/test/java/org/miracum/streams/ume/obdstofhir/processor/ObdsProcessorTest.java @@ -1,13 +1,60 @@ package org.miracum.streams.ume.obdstofhir.processor; +import ca.uhn.fhir.context.FhirContext; +import ca.uhn.fhir.parser.IParser; +import java.io.File; +import java.io.IOException; +import java.nio.file.Files; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import org.apache.commons.lang3.StringUtils; import org.junit.jupiter.api.BeforeAll; +import org.miracum.streams.ume.obdstofhir.model.MeldungExport; +import org.miracum.streams.ume.obdstofhir.model.MeldungExportList; +import org.miracum.streams.ume.obdstofhir.model.Tupel; import org.slf4j.Logger; import org.slf4j.LoggerFactory; +import org.springframework.util.ResourceUtils; public abstract class ObdsProcessorTest { private static final Logger log = LoggerFactory.getLogger(ObdsProcessorTest.class); + protected final FhirContext ctx = FhirContext.forR4(); + protected final IParser fhirParser = ctx.newJsonParser().setPrettyPrint(true); + @BeforeAll static void setUp() {} + + protected MeldungExportList buildMeldungExportList(List> xmlFileNames) + throws IOException, NumberFormatException { + var meldungExportList = new MeldungExportList(); + + int payloadId = 1; + + for (var xmlTupel : xmlFileNames) { + File xmlFile = ResourceUtils.getFile("classpath:" + xmlTupel.getFirst()); + String xmlContent = new String(Files.readAllBytes(xmlFile.toPath())); + + var meldungsId = StringUtils.substringBetween(xmlContent, "Meldung_ID=\"", "\" Melder_ID"); + var melderId = StringUtils.substringBetween(xmlContent, "Melder_ID=\"", "\">"); + var patId = StringUtils.substringBetween(xmlContent, "Patient_ID=\"", "\">"); + + Map payloadOnkoRessource = new HashMap<>(); + payloadOnkoRessource.put("ID", payloadId); + payloadOnkoRessource.put("REFERENZ_NUMMER", patId); + payloadOnkoRessource.put("LKR_MELDUNG", Integer.parseInt(meldungsId.replace(melderId, ""))); + payloadOnkoRessource.put("VERSIONSNUMMER", xmlTupel.getSecond()); + payloadOnkoRessource.put("XML_DATEN", xmlContent); + + MeldungExport meldungExport = new MeldungExport(); + meldungExport.getPayload(payloadOnkoRessource); + meldungExportList.addElement(meldungExport); + + payloadId++; + } + + return meldungExportList; + } } diff --git "a/src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsConditionProcessorTest.mapCondition_withGivenAdtXml.001_1.Pat_2Tumoren_TumorID_1_Diagnose.xml.003_Pat1_Tumor1_Therapie1_Behandlungsende_OP.xml.009_Pat1_Tumor1_Statusaenderung_Fernmeta_3x-\303\274berschreibt2xFernMetaausDIAGNOSE.xml.approved.fhir.json" "b/src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsConditionProcessorTest.mapCondition_withGivenAdtXml.001_1.Pat_2Tumoren_TumorID_1_Diagnose.xml.003_Pat1_Tumor1_Therapie1_Behandlungsende_OP.xml.009_Pat1_Tumor1_Statusaenderung_Fernmeta_3x-\303\274berschreibt2xFernMetaausDIAGNOSE.xml.approved.fhir.json" new file mode 100644 index 00000000..faf50f6e --- /dev/null +++ "b/src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsConditionProcessorTest.mapCondition_withGivenAdtXml.001_1.Pat_2Tumoren_TumorID_1_Diagnose.xml.003_Pat1_Tumor1_Therapie1_Behandlungsende_OP.xml.009_Pat1_Tumor1_Statusaenderung_Fernmeta_3x-\303\274berschreibt2xFernMetaausDIAGNOSE.xml.approved.fhir.json" @@ -0,0 +1,96 @@ +{ + "resourceType": "Bundle", + "type": "transaction", + "entry": [ { + "fullUrl": "Condition/a90ae2425e2d00616e04da0617c3617740c6f11363cc31df696eef9c06235616", + "resource": { + "resourceType": "Condition", + "id": "a90ae2425e2d00616e04da0617c3617740c6f11363cc31df696eef9c06235616", + "meta": { + "source": "UKER_ONKOSTAR.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Condition-Primaerdiagnose" ] + }, + "extension": [ { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-Fernmetastasen", + "valueReference": { + "reference": "Observation/eb9b082adf8afc80a6858bc05886c1ecb08b5caf7d2864198baad0903ac55baf" + } + }, { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-Fernmetastasen", + "valueReference": { + "reference": "Observation/7b3181b44891bb7bba0f7ebb2511285589df40eb54a6073e390ed8550fc3ad8d" + } + }, { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-Fernmetastasen", + "valueReference": { + "reference": "Observation/aa0f0ae0f151114fd167c207b9216685244dd8a17739f01e2e3fda9cada6491a" + } + }, { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-Fernmetastasen", + "valueReference": { + "reference": "Observation/a0bac97bc3de3b565faba74d49c0b6eb43751b07fa5deda2f63b75eb8db66147" + } + }, { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-Fernmetastasen", + "valueReference": { + "reference": "Observation/302e6b7f1b82d044c443cd186dad3eb3470351b10d6e0808fefcf9c99c354753" + } + }, { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-Fernmetastasen", + "valueReference": { + "reference": "Observation/734471546228b0e9385706399d6eeef9860ab8cb67536c07a0d9712d7bea302d" + } + } ], + "code": { + "coding": [ { + "system": "http://fhir.de/CodeSystem/bfarm/icd-10-gm", + "version": "2021", + "code": "C72.0" + } ] + }, + "bodySite": [ { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SeitenlokalisationCS", + "code": "T", + "display": "trifft nicht zu (Seitenangabe nicht sinnvoll, einschließlich Systemerkrankungen)" + }, { + "system": "http://snomed.info/sct", + "code": "396360001", + "display": "Tumor site not applicable (finding)" + } ] + } ], + "subject": { + "reference": "Patient/cb07d6456df4982ff6b8de92fc018b0d5fc9dab1d1e303e97bd0474699111b52", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555999" + } + }, + "onsetDateTime": "2021-03-18", + "stage": [ { + "assessment": [ { + "reference": "Observation/fc7cabc6beffc1605c782aa46a8a32df94aa5ef01b9c828e0671e2a643d0a2bc" + } ] + }, { + "assessment": [ { + "reference": "Observation/555236ab41f9cc4e258c40c578b4ffbcb355055b8977706c983a3f338b6298b1" + } ] + } ], + "evidence": [ { + "detail": [ { + "reference": "Observation/4d8b7cdb7f7e81ecfeceafb96ac5c4390ae37be6b3b38f21ba315389dccb040b" + } ] + } ] + }, + "request": { + "method": "PUT", + "url": "Condition/a90ae2425e2d00616e04da0617c3617740c6f11363cc31df696eef9c06235616" + } + } ] +} diff --git a/src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsConditionProcessorTest.mapCondition_withGivenAdtXml.001_1.Pat_2Tumoren_TumorID_1_Diagnose.xml.approved.fhir.json b/src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsConditionProcessorTest.mapCondition_withGivenAdtXml.001_1.Pat_2Tumoren_TumorID_1_Diagnose.xml.approved.fhir.json new file mode 100644 index 00000000..3cea4958 --- /dev/null +++ b/src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsConditionProcessorTest.mapCondition_withGivenAdtXml.001_1.Pat_2Tumoren_TumorID_1_Diagnose.xml.approved.fhir.json @@ -0,0 +1,91 @@ +{ + "resourceType": "Bundle", + "type": "transaction", + "entry": [ { + "fullUrl": "Condition/a90ae2425e2d00616e04da0617c3617740c6f11363cc31df696eef9c06235616", + "resource": { + "resourceType": "Condition", + "id": "a90ae2425e2d00616e04da0617c3617740c6f11363cc31df696eef9c06235616", + "meta": { + "source": "UKER_ONKOSTAR.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Condition-Primaerdiagnose" ] + }, + "extension": [ { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-Fernmetastasen", + "valueReference": { + "reference": "Observation/7b3181b44891bb7bba0f7ebb2511285589df40eb54a6073e390ed8550fc3ad8d" + } + }, { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-Fernmetastasen", + "valueReference": { + "reference": "Observation/aa0f0ae0f151114fd167c207b9216685244dd8a17739f01e2e3fda9cada6491a" + } + }, { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-Fernmetastasen", + "valueReference": { + "reference": "Observation/a0bac97bc3de3b565faba74d49c0b6eb43751b07fa5deda2f63b75eb8db66147" + } + }, { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-Fernmetastasen", + "valueReference": { + "reference": "Observation/302e6b7f1b82d044c443cd186dad3eb3470351b10d6e0808fefcf9c99c354753" + } + }, { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-Fernmetastasen", + "valueReference": { + "reference": "Observation/734471546228b0e9385706399d6eeef9860ab8cb67536c07a0d9712d7bea302d" + } + } ], + "code": { + "coding": [ { + "system": "http://fhir.de/CodeSystem/bfarm/icd-10-gm", + "version": "2021", + "code": "C72.0" + } ] + }, + "bodySite": [ { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SeitenlokalisationCS", + "code": "T", + "display": "trifft nicht zu (Seitenangabe nicht sinnvoll, einschließlich Systemerkrankungen)" + }, { + "system": "http://snomed.info/sct", + "code": "396360001", + "display": "Tumor site not applicable (finding)" + } ] + } ], + "subject": { + "reference": "Patient/cb07d6456df4982ff6b8de92fc018b0d5fc9dab1d1e303e97bd0474699111b52", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555999" + } + }, + "onsetDateTime": "2021-03-18", + "stage": [ { + "assessment": [ { + "reference": "Observation/fc7cabc6beffc1605c782aa46a8a32df94aa5ef01b9c828e0671e2a643d0a2bc" + } ] + }, { + "assessment": [ { + "reference": "Observation/555236ab41f9cc4e258c40c578b4ffbcb355055b8977706c983a3f338b6298b1" + } ] + } ], + "evidence": [ { + "detail": [ { + "reference": "Observation/4d8b7cdb7f7e81ecfeceafb96ac5c4390ae37be6b3b38f21ba315389dccb040b" + } ] + } ] + }, + "request": { + "method": "PUT", + "url": "Condition/a90ae2425e2d00616e04da0617c3617740c6f11363cc31df696eef9c06235616" + } + } ] +} diff --git a/src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsConditionProcessorTest.mapCondition_withGivenAdtXml.002_1.Pat_2Tumoren_TumorID_2_Diagnose.xml.approved.fhir.json b/src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsConditionProcessorTest.mapCondition_withGivenAdtXml.002_1.Pat_2Tumoren_TumorID_2_Diagnose.xml.approved.fhir.json new file mode 100644 index 00000000..534cd37b --- /dev/null +++ b/src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsConditionProcessorTest.mapCondition_withGivenAdtXml.002_1.Pat_2Tumoren_TumorID_2_Diagnose.xml.approved.fhir.json @@ -0,0 +1,60 @@ +{ + "resourceType": "Bundle", + "type": "transaction", + "entry": [ { + "fullUrl": "Condition/438ded78a47f0cc1921fd82237f9c5aaca5fa381ef2e5b4e65538087dd08d47c", + "resource": { + "resourceType": "Condition", + "id": "438ded78a47f0cc1921fd82237f9c5aaca5fa381ef2e5b4e65538087dd08d47c", + "meta": { + "source": "UKER_ONKOSTAR.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Condition-Primaerdiagnose" ] + }, + "code": { + "coding": [ { + "system": "http://fhir.de/CodeSystem/bfarm/icd-10-gm", + "version": "2021", + "code": "C41.01" + } ] + }, + "bodySite": [ { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SeitenlokalisationCS", + "code": "T", + "display": "trifft nicht zu (Seitenangabe nicht sinnvoll, einschließlich Systemerkrankungen)" + }, { + "system": "http://snomed.info/sct", + "code": "396360001", + "display": "Tumor site not applicable (finding)" + } ] + } ], + "subject": { + "reference": "Patient/cb07d6456df4982ff6b8de92fc018b0d5fc9dab1d1e303e97bd0474699111b52", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555999" + } + }, + "onsetDateTime": "2021-02-08", + "evidence": [ { + "detail": [ { + "reference": "Observation/c283276eb31614ec2e9ea44e9d844ff51c3de42b20cead14da926251a1ddbafc" + } ] + }, { + "detail": [ { + "reference": "Observation/5f8a74450706bd0d34767d104eeb16c99eb69bbaea1f6ce1049c87f09bea2df0" + } ] + } ] + }, + "request": { + "method": "PUT", + "url": "Condition/438ded78a47f0cc1921fd82237f9c5aaca5fa381ef2e5b4e65538087dd08d47c" + } + } ] +} diff --git a/src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsMedicationStatementProcessorTest.mapMedicationStatement_withGivenAdtXml.008_Pat3_Tumor1_Behandlungsende_SYST.xml.approved.fhir.json b/src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsMedicationStatementProcessorTest.mapMedicationStatement_withGivenAdtXml.008_Pat3_Tumor1_Behandlungsende_SYST.xml.approved.fhir.json new file mode 100644 index 00000000..c912cf2f --- /dev/null +++ b/src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsMedicationStatementProcessorTest.mapMedicationStatement_withGivenAdtXml.008_Pat3_Tumor1_Behandlungsende_SYST.xml.approved.fhir.json @@ -0,0 +1,340 @@ +{ + "resourceType": "Bundle", + "type": "transaction", + "entry": [ { + "fullUrl": "MedicationStatement/3a6f9e3df20464337ff932ea9833acdfc92c3dd4afa444f2d1bf900627eec020", + "resource": { + "resourceType": "MedicationStatement", + "id": "3a6f9e3df20464337ff932ea9833acdfc92c3dd4afa444f2d1bf900627eec020", + "meta": { + "source": "UKER_ONKOSTAR.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-MedicationStatement-Systemtherapie" ] + }, + "extension": [ { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-StellungZurOp", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SYSTStellungOPCS", + "code": "O", + "display": "ohne Bezug zu einer operativen Therapie" + } ] + } + }, { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-SYSTIntention", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SYSTIntentionCS", + "code": "K", + "display": "kurativ" + } ] + } + } ], + "status": "completed", + "category": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SYSTTherapieartCS", + "code": "CI", + "display": "Chemo- + Immun-/Antikörpertherapie" + } ] + }, + "medicationCodeableConcept": { + "extension": [ { + "url": "http://hl7.org/fhir/StructureDefinition/data-absent-reason", + "valueCode": "not-applicable" + } ] + }, + "subject": { + "reference": "Patient/358f64e184a86f78bdb65a8fd8b841e86ad0db7c97318b0f00eaf81832eb246f", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555777" + } + }, + "effectivePeriod": { + "start": "2021-05-22", + "end": "2021-07-20" + }, + "reasonReference": [ { + "reference": "Condition/8e6a9b1e5b4d768f616395dd89b82e4145a16941c08d17fe1bb8a70bc1353412" + } ] + }, + "request": { + "method": "PUT", + "url": "MedicationStatement/3a6f9e3df20464337ff932ea9833acdfc92c3dd4afa444f2d1bf900627eec020" + } + }, { + "fullUrl": "MedicationStatement/ea3bdcd0ac67e6103589595775d905b521ca5ce5370018e7b738e0806fde2821", + "resource": { + "resourceType": "MedicationStatement", + "id": "ea3bdcd0ac67e6103589595775d905b521ca5ce5370018e7b738e0806fde2821", + "meta": { + "source": "UKER_ONKOSTAR.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-MedicationStatement-Systemtherapie" ] + }, + "extension": [ { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-StellungZurOp", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SYSTStellungOPCS", + "code": "O", + "display": "ohne Bezug zu einer operativen Therapie" + } ] + } + }, { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-SYSTIntention", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SYSTIntentionCS", + "code": "K", + "display": "kurativ" + } ] + } + } ], + "partOf": [ { + "reference": "MedicationStatement/3a6f9e3df20464337ff932ea9833acdfc92c3dd4afa444f2d1bf900627eec020" + } ], + "status": "completed", + "category": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SYSTTherapieartCS", + "code": "CI", + "display": "Chemo- + Immun-/Antikörpertherapie" + } ] + }, + "medicationCodeableConcept": { + "text": "Cyclophosphamid" + }, + "subject": { + "reference": "Patient/358f64e184a86f78bdb65a8fd8b841e86ad0db7c97318b0f00eaf81832eb246f", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555777" + } + }, + "effectivePeriod": { + "start": "2021-05-22", + "end": "2021-07-20" + }, + "reasonReference": [ { + "reference": "Condition/8e6a9b1e5b4d768f616395dd89b82e4145a16941c08d17fe1bb8a70bc1353412" + } ] + }, + "request": { + "method": "PUT", + "url": "MedicationStatement/ea3bdcd0ac67e6103589595775d905b521ca5ce5370018e7b738e0806fde2821" + } + }, { + "fullUrl": "MedicationStatement/3eb18c984d23b8a3bbf02fe2c2cb385c5f9ec86602c8fb2749dae763b1ad79e5", + "resource": { + "resourceType": "MedicationStatement", + "id": "3eb18c984d23b8a3bbf02fe2c2cb385c5f9ec86602c8fb2749dae763b1ad79e5", + "meta": { + "source": "UKER_ONKOSTAR.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-MedicationStatement-Systemtherapie" ] + }, + "extension": [ { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-StellungZurOp", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SYSTStellungOPCS", + "code": "O", + "display": "ohne Bezug zu einer operativen Therapie" + } ] + } + }, { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-SYSTIntention", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SYSTIntentionCS", + "code": "K", + "display": "kurativ" + } ] + } + } ], + "partOf": [ { + "reference": "MedicationStatement/3a6f9e3df20464337ff932ea9833acdfc92c3dd4afa444f2d1bf900627eec020" + } ], + "status": "completed", + "category": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SYSTTherapieartCS", + "code": "CI", + "display": "Chemo- + Immun-/Antikörpertherapie" + } ] + }, + "medicationCodeableConcept": { + "text": "Methotrexat (MTX)" + }, + "subject": { + "reference": "Patient/358f64e184a86f78bdb65a8fd8b841e86ad0db7c97318b0f00eaf81832eb246f", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555777" + } + }, + "effectivePeriod": { + "start": "2021-05-22", + "end": "2021-07-20" + }, + "reasonReference": [ { + "reference": "Condition/8e6a9b1e5b4d768f616395dd89b82e4145a16941c08d17fe1bb8a70bc1353412" + } ] + }, + "request": { + "method": "PUT", + "url": "MedicationStatement/3eb18c984d23b8a3bbf02fe2c2cb385c5f9ec86602c8fb2749dae763b1ad79e5" + } + }, { + "fullUrl": "MedicationStatement/328a01d32491f06ac6ab8564d059cc313390645329af4539a2185cafb7c92c8d", + "resource": { + "resourceType": "MedicationStatement", + "id": "328a01d32491f06ac6ab8564d059cc313390645329af4539a2185cafb7c92c8d", + "meta": { + "source": "UKER_ONKOSTAR.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-MedicationStatement-Systemtherapie" ] + }, + "extension": [ { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-StellungZurOp", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SYSTStellungOPCS", + "code": "O", + "display": "ohne Bezug zu einer operativen Therapie" + } ] + } + }, { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-SYSTIntention", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SYSTIntentionCS", + "code": "K", + "display": "kurativ" + } ] + } + } ], + "partOf": [ { + "reference": "MedicationStatement/3a6f9e3df20464337ff932ea9833acdfc92c3dd4afa444f2d1bf900627eec020" + } ], + "status": "completed", + "category": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SYSTTherapieartCS", + "code": "CI", + "display": "Chemo- + Immun-/Antikörpertherapie" + } ] + }, + "medicationCodeableConcept": { + "text": "Cytarabin (AraC)" + }, + "subject": { + "reference": "Patient/358f64e184a86f78bdb65a8fd8b841e86ad0db7c97318b0f00eaf81832eb246f", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555777" + } + }, + "effectivePeriod": { + "start": "2021-05-22", + "end": "2021-07-20" + }, + "reasonReference": [ { + "reference": "Condition/8e6a9b1e5b4d768f616395dd89b82e4145a16941c08d17fe1bb8a70bc1353412" + } ] + }, + "request": { + "method": "PUT", + "url": "MedicationStatement/328a01d32491f06ac6ab8564d059cc313390645329af4539a2185cafb7c92c8d" + } + }, { + "fullUrl": "MedicationStatement/d2aa80723b3d9fa509c68ef373c0963fb20bffe801aeecc72c81c806160ddd0f", + "resource": { + "resourceType": "MedicationStatement", + "id": "d2aa80723b3d9fa509c68ef373c0963fb20bffe801aeecc72c81c806160ddd0f", + "meta": { + "source": "UKER_ONKOSTAR.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-MedicationStatement-Systemtherapie" ] + }, + "extension": [ { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-StellungZurOp", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SYSTStellungOPCS", + "code": "O", + "display": "ohne Bezug zu einer operativen Therapie" + } ] + } + }, { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-SYSTIntention", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SYSTIntentionCS", + "code": "K", + "display": "kurativ" + } ] + } + } ], + "partOf": [ { + "reference": "MedicationStatement/3a6f9e3df20464337ff932ea9833acdfc92c3dd4afa444f2d1bf900627eec020" + } ], + "status": "completed", + "category": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SYSTTherapieartCS", + "code": "CI", + "display": "Chemo- + Immun-/Antikörpertherapie" + } ] + }, + "medicationCodeableConcept": { + "text": "Mercaptopurin (6-MP, Purinethol)" + }, + "subject": { + "reference": "Patient/358f64e184a86f78bdb65a8fd8b841e86ad0db7c97318b0f00eaf81832eb246f", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555777" + } + }, + "effectivePeriod": { + "start": "2021-05-22", + "end": "2021-07-20" + }, + "reasonReference": [ { + "reference": "Condition/8e6a9b1e5b4d768f616395dd89b82e4145a16941c08d17fe1bb8a70bc1353412" + } ] + }, + "request": { + "method": "PUT", + "url": "MedicationStatement/d2aa80723b3d9fa509c68ef373c0963fb20bffe801aeecc72c81c806160ddd0f" + } + } ] +} diff --git a/src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsMedicationStatementProcessorTest.mapMedicationStatement_withGivenAdtXml.008_Pat3_Tumor1_Behandlungsende_SYST.xml.received.approved.json b/src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsMedicationStatementProcessorTest.mapMedicationStatement_withGivenAdtXml.008_Pat3_Tumor1_Behandlungsende_SYST.xml.received.approved.json new file mode 100644 index 00000000..c912cf2f --- /dev/null +++ b/src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsMedicationStatementProcessorTest.mapMedicationStatement_withGivenAdtXml.008_Pat3_Tumor1_Behandlungsende_SYST.xml.received.approved.json @@ -0,0 +1,340 @@ +{ + "resourceType": "Bundle", + "type": "transaction", + "entry": [ { + "fullUrl": "MedicationStatement/3a6f9e3df20464337ff932ea9833acdfc92c3dd4afa444f2d1bf900627eec020", + "resource": { + "resourceType": "MedicationStatement", + "id": "3a6f9e3df20464337ff932ea9833acdfc92c3dd4afa444f2d1bf900627eec020", + "meta": { + "source": "UKER_ONKOSTAR.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-MedicationStatement-Systemtherapie" ] + }, + "extension": [ { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-StellungZurOp", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SYSTStellungOPCS", + "code": "O", + "display": "ohne Bezug zu einer operativen Therapie" + } ] + } + }, { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-SYSTIntention", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SYSTIntentionCS", + "code": "K", + "display": "kurativ" + } ] + } + } ], + "status": "completed", + "category": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SYSTTherapieartCS", + "code": "CI", + "display": "Chemo- + Immun-/Antikörpertherapie" + } ] + }, + "medicationCodeableConcept": { + "extension": [ { + "url": "http://hl7.org/fhir/StructureDefinition/data-absent-reason", + "valueCode": "not-applicable" + } ] + }, + "subject": { + "reference": "Patient/358f64e184a86f78bdb65a8fd8b841e86ad0db7c97318b0f00eaf81832eb246f", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555777" + } + }, + "effectivePeriod": { + "start": "2021-05-22", + "end": "2021-07-20" + }, + "reasonReference": [ { + "reference": "Condition/8e6a9b1e5b4d768f616395dd89b82e4145a16941c08d17fe1bb8a70bc1353412" + } ] + }, + "request": { + "method": "PUT", + "url": "MedicationStatement/3a6f9e3df20464337ff932ea9833acdfc92c3dd4afa444f2d1bf900627eec020" + } + }, { + "fullUrl": "MedicationStatement/ea3bdcd0ac67e6103589595775d905b521ca5ce5370018e7b738e0806fde2821", + "resource": { + "resourceType": "MedicationStatement", + "id": "ea3bdcd0ac67e6103589595775d905b521ca5ce5370018e7b738e0806fde2821", + "meta": { + "source": "UKER_ONKOSTAR.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-MedicationStatement-Systemtherapie" ] + }, + "extension": [ { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-StellungZurOp", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SYSTStellungOPCS", + "code": "O", + "display": "ohne Bezug zu einer operativen Therapie" + } ] + } + }, { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-SYSTIntention", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SYSTIntentionCS", + "code": "K", + "display": "kurativ" + } ] + } + } ], + "partOf": [ { + "reference": "MedicationStatement/3a6f9e3df20464337ff932ea9833acdfc92c3dd4afa444f2d1bf900627eec020" + } ], + "status": "completed", + "category": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SYSTTherapieartCS", + "code": "CI", + "display": "Chemo- + Immun-/Antikörpertherapie" + } ] + }, + "medicationCodeableConcept": { + "text": "Cyclophosphamid" + }, + "subject": { + "reference": "Patient/358f64e184a86f78bdb65a8fd8b841e86ad0db7c97318b0f00eaf81832eb246f", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555777" + } + }, + "effectivePeriod": { + "start": "2021-05-22", + "end": "2021-07-20" + }, + "reasonReference": [ { + "reference": "Condition/8e6a9b1e5b4d768f616395dd89b82e4145a16941c08d17fe1bb8a70bc1353412" + } ] + }, + "request": { + "method": "PUT", + "url": "MedicationStatement/ea3bdcd0ac67e6103589595775d905b521ca5ce5370018e7b738e0806fde2821" + } + }, { + "fullUrl": "MedicationStatement/3eb18c984d23b8a3bbf02fe2c2cb385c5f9ec86602c8fb2749dae763b1ad79e5", + "resource": { + "resourceType": "MedicationStatement", + "id": "3eb18c984d23b8a3bbf02fe2c2cb385c5f9ec86602c8fb2749dae763b1ad79e5", + "meta": { + "source": "UKER_ONKOSTAR.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-MedicationStatement-Systemtherapie" ] + }, + "extension": [ { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-StellungZurOp", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SYSTStellungOPCS", + "code": "O", + "display": "ohne Bezug zu einer operativen Therapie" + } ] + } + }, { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-SYSTIntention", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SYSTIntentionCS", + "code": "K", + "display": "kurativ" + } ] + } + } ], + "partOf": [ { + "reference": "MedicationStatement/3a6f9e3df20464337ff932ea9833acdfc92c3dd4afa444f2d1bf900627eec020" + } ], + "status": "completed", + "category": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SYSTTherapieartCS", + "code": "CI", + "display": "Chemo- + Immun-/Antikörpertherapie" + } ] + }, + "medicationCodeableConcept": { + "text": "Methotrexat (MTX)" + }, + "subject": { + "reference": "Patient/358f64e184a86f78bdb65a8fd8b841e86ad0db7c97318b0f00eaf81832eb246f", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555777" + } + }, + "effectivePeriod": { + "start": "2021-05-22", + "end": "2021-07-20" + }, + "reasonReference": [ { + "reference": "Condition/8e6a9b1e5b4d768f616395dd89b82e4145a16941c08d17fe1bb8a70bc1353412" + } ] + }, + "request": { + "method": "PUT", + "url": "MedicationStatement/3eb18c984d23b8a3bbf02fe2c2cb385c5f9ec86602c8fb2749dae763b1ad79e5" + } + }, { + "fullUrl": "MedicationStatement/328a01d32491f06ac6ab8564d059cc313390645329af4539a2185cafb7c92c8d", + "resource": { + "resourceType": "MedicationStatement", + "id": "328a01d32491f06ac6ab8564d059cc313390645329af4539a2185cafb7c92c8d", + "meta": { + "source": "UKER_ONKOSTAR.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-MedicationStatement-Systemtherapie" ] + }, + "extension": [ { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-StellungZurOp", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SYSTStellungOPCS", + "code": "O", + "display": "ohne Bezug zu einer operativen Therapie" + } ] + } + }, { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-SYSTIntention", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SYSTIntentionCS", + "code": "K", + "display": "kurativ" + } ] + } + } ], + "partOf": [ { + "reference": "MedicationStatement/3a6f9e3df20464337ff932ea9833acdfc92c3dd4afa444f2d1bf900627eec020" + } ], + "status": "completed", + "category": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SYSTTherapieartCS", + "code": "CI", + "display": "Chemo- + Immun-/Antikörpertherapie" + } ] + }, + "medicationCodeableConcept": { + "text": "Cytarabin (AraC)" + }, + "subject": { + "reference": "Patient/358f64e184a86f78bdb65a8fd8b841e86ad0db7c97318b0f00eaf81832eb246f", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555777" + } + }, + "effectivePeriod": { + "start": "2021-05-22", + "end": "2021-07-20" + }, + "reasonReference": [ { + "reference": "Condition/8e6a9b1e5b4d768f616395dd89b82e4145a16941c08d17fe1bb8a70bc1353412" + } ] + }, + "request": { + "method": "PUT", + "url": "MedicationStatement/328a01d32491f06ac6ab8564d059cc313390645329af4539a2185cafb7c92c8d" + } + }, { + "fullUrl": "MedicationStatement/d2aa80723b3d9fa509c68ef373c0963fb20bffe801aeecc72c81c806160ddd0f", + "resource": { + "resourceType": "MedicationStatement", + "id": "d2aa80723b3d9fa509c68ef373c0963fb20bffe801aeecc72c81c806160ddd0f", + "meta": { + "source": "UKER_ONKOSTAR.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-MedicationStatement-Systemtherapie" ] + }, + "extension": [ { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-StellungZurOp", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SYSTStellungOPCS", + "code": "O", + "display": "ohne Bezug zu einer operativen Therapie" + } ] + } + }, { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-SYSTIntention", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SYSTIntentionCS", + "code": "K", + "display": "kurativ" + } ] + } + } ], + "partOf": [ { + "reference": "MedicationStatement/3a6f9e3df20464337ff932ea9833acdfc92c3dd4afa444f2d1bf900627eec020" + } ], + "status": "completed", + "category": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/SYSTTherapieartCS", + "code": "CI", + "display": "Chemo- + Immun-/Antikörpertherapie" + } ] + }, + "medicationCodeableConcept": { + "text": "Mercaptopurin (6-MP, Purinethol)" + }, + "subject": { + "reference": "Patient/358f64e184a86f78bdb65a8fd8b841e86ad0db7c97318b0f00eaf81832eb246f", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555777" + } + }, + "effectivePeriod": { + "start": "2021-05-22", + "end": "2021-07-20" + }, + "reasonReference": [ { + "reference": "Condition/8e6a9b1e5b4d768f616395dd89b82e4145a16941c08d17fe1bb8a70bc1353412" + } ] + }, + "request": { + "method": "PUT", + "url": "MedicationStatement/d2aa80723b3d9fa509c68ef373c0963fb20bffe801aeecc72c81c806160ddd0f" + } + } ] +} diff --git a/src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsObservationProcessorTest.mapObservation_withGivenAdtXml.001_1.Pat_2Tumoren_TumorID_1_Diagnose.xml.003_Pat1_Tumor1_Therapie1_Behandlungsende_OP.xml.010_Pat2_Tumor1_Tod.xml.approved.fhir.json b/src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsObservationProcessorTest.mapObservation_withGivenAdtXml.001_1.Pat_2Tumoren_TumorID_1_Diagnose.xml.003_Pat1_Tumor1_Therapie1_Behandlungsende_OP.xml.010_Pat2_Tumor1_Tod.xml.approved.fhir.json new file mode 100644 index 00000000..c340ac58 --- /dev/null +++ b/src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsObservationProcessorTest.mapObservation_withGivenAdtXml.001_1.Pat_2Tumoren_TumorID_1_Diagnose.xml.003_Pat1_Tumor1_Therapie1_Behandlungsende_OP.xml.010_Pat2_Tumor1_Tod.xml.approved.fhir.json @@ -0,0 +1,677 @@ +{ + "resourceType": "Bundle", + "type": "transaction", + "entry": [ { + "fullUrl": "Observation/4d8b7cdb7f7e81ecfeceafb96ac5c4390ae37be6b3b38f21ba315389dccb040b", + "resource": { + "resourceType": "Observation", + "id": "4d8b7cdb7f7e81ecfeceafb96ac5c4390ae37be6b3b38f21ba315389dccb040b", + "meta": { + "source": "UKER.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Observation-Histologie" ] + }, + "status": "final", + "category": [ { + "coding": [ { + "system": "http://hl7.org/fhir/observation-category", + "code": "laboratory", + "display": "Laboratory" + } ] + } ], + "code": { + "coding": [ { + "system": "http://loinc.org", + "code": "59847-4", + "display": "Histology and Behavior ICD-O-3 Cancer" + } ] + }, + "subject": { + "reference": "Patient/cb07d6456df4982ff6b8de92fc018b0d5fc9dab1d1e303e97bd0474699111b52", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555999" + } + }, + "effectiveDateTime": "2021-03-20", + "valueCodeableConcept": { + "coding": [ { + "system": "urn:oid:2.16.840.1.113883.6.43.1", + "version": "32", + "code": "9391/8" + } ] + }, + "hasMember": [ { + "reference": "Observation/98af71c27bc7328e3d2e184eca58d8e402a246efda16516f5382efba6fda4e50" + } ] + }, + "request": { + "method": "PUT", + "url": "Observation/4d8b7cdb7f7e81ecfeceafb96ac5c4390ae37be6b3b38f21ba315389dccb040b" + } + }, { + "fullUrl": "Observation/98af71c27bc7328e3d2e184eca58d8e402a246efda16516f5382efba6fda4e50", + "resource": { + "resourceType": "Observation", + "id": "98af71c27bc7328e3d2e184eca58d8e402a246efda16516f5382efba6fda4e50", + "meta": { + "source": "UKER.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Observation-Grading" ] + }, + "status": "final", + "category": [ { + "coding": [ { + "system": "http://hl7.org/fhir/observation-category", + "code": "laboratory", + "display": "Laboratory" + } ] + } ], + "code": { + "coding": [ { + "system": "http://loinc.org", + "code": "59542-1", + "display": "Grade pathology value Cancer" + } ] + }, + "subject": { + "reference": "Patient/cb07d6456df4982ff6b8de92fc018b0d5fc9dab1d1e303e97bd0474699111b52", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555999" + } + }, + "effectiveDateTime": "2021-03-20", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/GradingCS", + "code": "U", + "display": "unbekannt" + } ] + } + }, + "request": { + "method": "PUT", + "url": "Observation/98af71c27bc7328e3d2e184eca58d8e402a246efda16516f5382efba6fda4e50" + } + }, { + "fullUrl": "Observation/fc7cabc6beffc1605c782aa46a8a32df94aa5ef01b9c828e0671e2a643d0a2bc", + "resource": { + "resourceType": "Observation", + "id": "fc7cabc6beffc1605c782aa46a8a32df94aa5ef01b9c828e0671e2a643d0a2bc", + "meta": { + "source": "UKER.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Observation-TNMc" ] + }, + "status": "final", + "category": [ { + "coding": [ { + "system": "http://hl7.org/fhir/observation-category", + "code": "laboratory", + "display": "Laboratory" + } ] + } ], + "code": { + "coding": [ { + "system": "http://loinc.org", + "code": "21908-9", + "display": "Stage group.clinical Cancer" + } ] + }, + "subject": { + "reference": "Patient/cb07d6456df4982ff6b8de92fc018b0d5fc9dab1d1e303e97bd0474699111b52", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555999" + } + }, + "effectiveDateTime": "2021-10-21", + "component": [ { + "extension": [ { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-TNMcpuPraefix", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/TNMcpuPraefixTCS", + "code": "c", + "display": "Kategorie wurde durch klinische Angaben festgestellt, bzw. erfüllt die Kriterien für p nicht" + } ] + } + } ], + "code": { + "coding": [ { + "system": "http://loinc.org", + "code": "21905-5", + "display": "Primary tumor.clinical Cancer" + } ] + }, + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/TNMTCS", + "code": "0", + "display": "0" + } ] + } + }, { + "extension": [ { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-TNMcpuPraefix", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/TNMcpuPraefixTCS", + "code": "c", + "display": "Kategorie wurde durch klinische Angaben festgestellt, bzw. erfüllt die Kriterien für p nicht" + } ] + } + } ], + "code": { + "coding": [ { + "system": "http://loinc.org", + "code": "21906-3", + "display": "Regional lymph nodes.clinical" + } ] + }, + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/TNMNCS", + "code": "1", + "display": "1" + } ] + } + }, { + "extension": [ { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-TNMcpuPraefix", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/TNMcpuPraefixTCS", + "code": "c", + "display": "Kategorie wurde durch klinische Angaben festgestellt, bzw. erfüllt die Kriterien für p nicht" + } ] + } + } ], + "code": { + "coding": [ { + "system": "http://loinc.org", + "code": "21907-1", + "display": "Distant metastases.clinical [Class] Cancer" + } ] + }, + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/TNMMCS", + "code": "0", + "display": "0" + } ] + } + } ] + }, + "request": { + "method": "PUT", + "url": "Observation/fc7cabc6beffc1605c782aa46a8a32df94aa5ef01b9c828e0671e2a643d0a2bc" + } + }, { + "fullUrl": "Observation/555236ab41f9cc4e258c40c578b4ffbcb355055b8977706c983a3f338b6298b1", + "resource": { + "resourceType": "Observation", + "id": "555236ab41f9cc4e258c40c578b4ffbcb355055b8977706c983a3f338b6298b1", + "meta": { + "source": "UKER.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Observation-TNMp" ] + }, + "status": "final", + "category": [ { + "coding": [ { + "system": "http://hl7.org/fhir/observation-category", + "code": "laboratory", + "display": "Laboratory" + } ] + } ], + "code": { + "coding": [ { + "system": "http://loinc.org", + "code": "21902-2", + "display": "Stage group.pathology Cancer" + } ] + }, + "subject": { + "reference": "Patient/cb07d6456df4982ff6b8de92fc018b0d5fc9dab1d1e303e97bd0474699111b52", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555999" + } + }, + "effectiveDateTime": "2021-03-17", + "component": [ { + "extension": [ { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-TNMcpuPraefix", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/TNMcpuPraefixTCS", + "code": "p", + "display": "Feststellung der Kategorie erfolgte durch eine pathohistologische Untersuchung, mit der auch der höchste Grad der jeweiligen Kategorie hätte festgestellt werden können" + } ] + } + } ], + "code": { + "coding": [ { + "system": "http://loinc.org", + "code": "21899-0", + "display": "Primary tumor.pathology Cancer" + } ] + }, + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/TNMTCS", + "code": "is", + "display": "is" + } ] + } + }, { + "extension": [ { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-TNMcpuPraefix", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/TNMcpuPraefixTCS", + "code": "c", + "display": "Kategorie wurde durch klinische Angaben festgestellt, bzw. erfüllt die Kriterien für p nicht" + } ] + } + } ], + "code": { + "coding": [ { + "system": "http://loinc.org", + "code": "21900-6", + "display": "Regional lymph nodes.pathology" + } ] + }, + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/TNMNCS", + "code": "0", + "display": "0" + } ] + } + }, { + "extension": [ { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-TNMcpuPraefix", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/TNMcpuPraefixTCS", + "code": "c", + "display": "Kategorie wurde durch klinische Angaben festgestellt, bzw. erfüllt die Kriterien für p nicht" + } ] + } + } ], + "code": { + "coding": [ { + "system": "http://loinc.org", + "code": "21901-4", + "display": "Distant metastases.pathology [Class] Cancer" + } ] + }, + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/TNMMCS", + "code": "0", + "display": "0" + } ] + } + } ] + }, + "request": { + "method": "PUT", + "url": "Observation/555236ab41f9cc4e258c40c578b4ffbcb355055b8977706c983a3f338b6298b1" + } + }, { + "fullUrl": "Observation/7b3181b44891bb7bba0f7ebb2511285589df40eb54a6073e390ed8550fc3ad8d", + "resource": { + "resourceType": "Observation", + "id": "7b3181b44891bb7bba0f7ebb2511285589df40eb54a6073e390ed8550fc3ad8d", + "meta": { + "source": "UKER.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Observation-Fernmetastasen" ] + }, + "status": "final", + "category": [ { + "coding": [ { + "system": "http://hl7.org/fhir/observation-category", + "code": "laboratory", + "display": "Laboratory" + } ] + } ], + "code": { + "coding": [ { + "system": "http://loinc.org", + "code": "21907-1", + "display": "Distant metastases.clinical" + } ] + }, + "subject": { + "reference": "Patient/cb07d6456df4982ff6b8de92fc018b0d5fc9dab1d1e303e97bd0474699111b52", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555999" + } + }, + "effectiveDateTime": "2021-02-12", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/JNUCS", + "code": "J", + "display": "Ja" + } ] + }, + "bodySite": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/FMLokalisationCS", + "code": "OTH", + "display": "Andere Organe" + } ] + } + }, + "request": { + "method": "PUT", + "url": "Observation/7b3181b44891bb7bba0f7ebb2511285589df40eb54a6073e390ed8550fc3ad8d" + } + }, { + "fullUrl": "Observation/aa0f0ae0f151114fd167c207b9216685244dd8a17739f01e2e3fda9cada6491a", + "resource": { + "resourceType": "Observation", + "id": "aa0f0ae0f151114fd167c207b9216685244dd8a17739f01e2e3fda9cada6491a", + "meta": { + "source": "UKER.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Observation-Fernmetastasen" ] + }, + "status": "final", + "category": [ { + "coding": [ { + "system": "http://hl7.org/fhir/observation-category", + "code": "laboratory", + "display": "Laboratory" + } ] + } ], + "code": { + "coding": [ { + "system": "http://loinc.org", + "code": "21907-1", + "display": "Distant metastases.clinical" + } ] + }, + "subject": { + "reference": "Patient/cb07d6456df4982ff6b8de92fc018b0d5fc9dab1d1e303e97bd0474699111b52", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555999" + } + }, + "effectiveDateTime": "2021-08-26", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/JNUCS", + "code": "J", + "display": "Ja" + } ] + }, + "bodySite": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/FMLokalisationCS", + "code": "OSS", + "display": "Knochen" + } ] + } + }, + "request": { + "method": "PUT", + "url": "Observation/aa0f0ae0f151114fd167c207b9216685244dd8a17739f01e2e3fda9cada6491a" + } + }, { + "fullUrl": "Observation/a0bac97bc3de3b565faba74d49c0b6eb43751b07fa5deda2f63b75eb8db66147", + "resource": { + "resourceType": "Observation", + "id": "a0bac97bc3de3b565faba74d49c0b6eb43751b07fa5deda2f63b75eb8db66147", + "meta": { + "source": "UKER.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Observation-Fernmetastasen" ] + }, + "status": "final", + "category": [ { + "coding": [ { + "system": "http://hl7.org/fhir/observation-category", + "code": "laboratory", + "display": "Laboratory" + } ] + } ], + "code": { + "coding": [ { + "system": "http://loinc.org", + "code": "21907-1", + "display": "Distant metastases.clinical" + } ] + }, + "subject": { + "reference": "Patient/cb07d6456df4982ff6b8de92fc018b0d5fc9dab1d1e303e97bd0474699111b52", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555999" + } + }, + "effectiveDateTime": "2021-02-12", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/JNUCS", + "code": "J", + "display": "Ja" + } ] + }, + "bodySite": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/FMLokalisationCS", + "code": "OTH", + "display": "Andere Organe" + } ] + } + }, + "request": { + "method": "PUT", + "url": "Observation/a0bac97bc3de3b565faba74d49c0b6eb43751b07fa5deda2f63b75eb8db66147" + } + }, { + "fullUrl": "Observation/302e6b7f1b82d044c443cd186dad3eb3470351b10d6e0808fefcf9c99c354753", + "resource": { + "resourceType": "Observation", + "id": "302e6b7f1b82d044c443cd186dad3eb3470351b10d6e0808fefcf9c99c354753", + "meta": { + "source": "UKER.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Observation-Fernmetastasen" ] + }, + "status": "final", + "category": [ { + "coding": [ { + "system": "http://hl7.org/fhir/observation-category", + "code": "laboratory", + "display": "Laboratory" + } ] + } ], + "code": { + "coding": [ { + "system": "http://loinc.org", + "code": "21907-1", + "display": "Distant metastases.clinical" + } ] + }, + "subject": { + "reference": "Patient/cb07d6456df4982ff6b8de92fc018b0d5fc9dab1d1e303e97bd0474699111b52", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555999" + } + }, + "effectiveDateTime": "2021-02-12", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/JNUCS", + "code": "J", + "display": "Ja" + } ] + }, + "bodySite": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/FMLokalisationCS", + "code": "HEP", + "display": "Leber" + } ] + } + }, + "request": { + "method": "PUT", + "url": "Observation/302e6b7f1b82d044c443cd186dad3eb3470351b10d6e0808fefcf9c99c354753" + } + }, { + "fullUrl": "Observation/734471546228b0e9385706399d6eeef9860ab8cb67536c07a0d9712d7bea302d", + "resource": { + "resourceType": "Observation", + "id": "734471546228b0e9385706399d6eeef9860ab8cb67536c07a0d9712d7bea302d", + "meta": { + "source": "UKER.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Observation-Fernmetastasen" ] + }, + "status": "final", + "category": [ { + "coding": [ { + "system": "http://hl7.org/fhir/observation-category", + "code": "laboratory", + "display": "Laboratory" + } ] + } ], + "code": { + "coding": [ { + "system": "http://loinc.org", + "code": "21907-1", + "display": "Distant metastases.clinical" + } ] + }, + "subject": { + "reference": "Patient/cb07d6456df4982ff6b8de92fc018b0d5fc9dab1d1e303e97bd0474699111b52", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555999" + } + }, + "effectiveDateTime": "2021-02-12", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/JNUCS", + "code": "J", + "display": "Ja" + } ] + }, + "bodySite": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/FMLokalisationCS", + "code": "LYM", + "display": "Lymphknoten" + } ] + } + }, + "request": { + "method": "PUT", + "url": "Observation/734471546228b0e9385706399d6eeef9860ab8cb67536c07a0d9712d7bea302d" + } + }, { + "fullUrl": "Observation/caeb45a6afede2449dbf70201c0f5db2670dd8a0092432cfaa4f4b46bb4b4b18", + "resource": { + "resourceType": "Observation", + "id": "caeb45a6afede2449dbf70201c0f5db2670dd8a0092432cfaa4f4b46bb4b4b18", + "meta": { + "source": "UKER.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Observation-TodUrsache" ] + }, + "status": "final", + "code": { + "coding": [ { + "system": "http://loinc.org", + "code": "68343-3", + "display": "Primary cause of death" + } ] + }, + "subject": { + "reference": "Patient/cb07d6456df4982ff6b8de92fc018b0d5fc9dab1d1e303e97bd0474699111b52", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555999" + } + }, + "effectiveDateTime": "2021-04-10", + "valueCodeableConcept": { + "coding": [ { + "system": "http://fhir.de/CodeSystem/bfarm/icd-10-gm", + "code": "R68.8" + }, { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/JNUCS", + "code": "J", + "display": "Ja" + } ] + } + }, + "request": { + "method": "PUT", + "url": "Observation/caeb45a6afede2449dbf70201c0f5db2670dd8a0092432cfaa4f4b46bb4b4b18" + } + } ] +} diff --git a/src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsObservationProcessorTest.mapObservation_withGivenAdtXml.001_1.Pat_2Tumoren_TumorID_1_Diagnose.xml.approved.fhir.json b/src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsObservationProcessorTest.mapObservation_withGivenAdtXml.001_1.Pat_2Tumoren_TumorID_1_Diagnose.xml.approved.fhir.json new file mode 100644 index 00000000..27cef30e --- /dev/null +++ b/src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsObservationProcessorTest.mapObservation_withGivenAdtXml.001_1.Pat_2Tumoren_TumorID_1_Diagnose.xml.approved.fhir.json @@ -0,0 +1,581 @@ +{ + "resourceType": "Bundle", + "type": "transaction", + "entry": [ { + "fullUrl": "Observation/4d8b7cdb7f7e81ecfeceafb96ac5c4390ae37be6b3b38f21ba315389dccb040b", + "resource": { + "resourceType": "Observation", + "id": "4d8b7cdb7f7e81ecfeceafb96ac5c4390ae37be6b3b38f21ba315389dccb040b", + "meta": { + "source": "UKER_ONKOSTAR.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Observation-Histologie" ] + }, + "status": "final", + "category": [ { + "coding": [ { + "system": "http://hl7.org/fhir/observation-category", + "code": "laboratory", + "display": "Laboratory" + } ] + } ], + "code": { + "coding": [ { + "system": "http://loinc.org", + "code": "59847-4", + "display": "Histology and Behavior ICD-O-3 Cancer" + } ] + }, + "subject": { + "reference": "Patient/cb07d6456df4982ff6b8de92fc018b0d5fc9dab1d1e303e97bd0474699111b52", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555999" + } + }, + "effectiveDateTime": "2021-03-18", + "valueCodeableConcept": { + "coding": [ { + "system": "urn:oid:2.16.840.1.113883.6.43.1", + "version": "32", + "code": "9391/3" + } ] + }, + "hasMember": [ { + "reference": "Observation/98af71c27bc7328e3d2e184eca58d8e402a246efda16516f5382efba6fda4e50" + } ] + }, + "request": { + "method": "PUT", + "url": "Observation/4d8b7cdb7f7e81ecfeceafb96ac5c4390ae37be6b3b38f21ba315389dccb040b" + } + }, { + "fullUrl": "Observation/98af71c27bc7328e3d2e184eca58d8e402a246efda16516f5382efba6fda4e50", + "resource": { + "resourceType": "Observation", + "id": "98af71c27bc7328e3d2e184eca58d8e402a246efda16516f5382efba6fda4e50", + "meta": { + "source": "UKER_ONKOSTAR.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Observation-Grading" ] + }, + "status": "final", + "category": [ { + "coding": [ { + "system": "http://hl7.org/fhir/observation-category", + "code": "laboratory", + "display": "Laboratory" + } ] + } ], + "code": { + "coding": [ { + "system": "http://loinc.org", + "code": "59542-1", + "display": "Grade pathology value Cancer" + } ] + }, + "subject": { + "reference": "Patient/cb07d6456df4982ff6b8de92fc018b0d5fc9dab1d1e303e97bd0474699111b52", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555999" + } + }, + "effectiveDateTime": "2021-03-18", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/GradingCS", + "code": "T", + "display": "trifft nicht zu" + } ] + } + }, + "request": { + "method": "PUT", + "url": "Observation/98af71c27bc7328e3d2e184eca58d8e402a246efda16516f5382efba6fda4e50" + } + }, { + "fullUrl": "Observation/fc7cabc6beffc1605c782aa46a8a32df94aa5ef01b9c828e0671e2a643d0a2bc", + "resource": { + "resourceType": "Observation", + "id": "fc7cabc6beffc1605c782aa46a8a32df94aa5ef01b9c828e0671e2a643d0a2bc", + "meta": { + "source": "UKER_ONKOSTAR.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Observation-TNMc" ] + }, + "status": "final", + "category": [ { + "coding": [ { + "system": "http://hl7.org/fhir/observation-category", + "code": "laboratory", + "display": "Laboratory" + } ] + } ], + "code": { + "coding": [ { + "system": "http://loinc.org", + "code": "21908-9", + "display": "Stage group.clinical Cancer" + } ] + }, + "subject": { + "reference": "Patient/cb07d6456df4982ff6b8de92fc018b0d5fc9dab1d1e303e97bd0474699111b52", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555999" + } + }, + "effectiveDateTime": "2021-10-21", + "component": [ { + "extension": [ { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-TNMcpuPraefix", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/TNMcpuPraefixTCS", + "code": "c", + "display": "Kategorie wurde durch klinische Angaben festgestellt, bzw. erfüllt die Kriterien für p nicht" + } ] + } + } ], + "code": { + "coding": [ { + "system": "http://loinc.org", + "code": "21905-5", + "display": "Primary tumor.clinical Cancer" + } ] + }, + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/TNMTCS", + "code": "0", + "display": "0" + } ] + } + }, { + "extension": [ { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-TNMcpuPraefix", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/TNMcpuPraefixTCS", + "code": "c", + "display": "Kategorie wurde durch klinische Angaben festgestellt, bzw. erfüllt die Kriterien für p nicht" + } ] + } + } ], + "code": { + "coding": [ { + "system": "http://loinc.org", + "code": "21906-3", + "display": "Regional lymph nodes.clinical" + } ] + }, + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/TNMNCS", + "code": "1", + "display": "1" + } ] + } + }, { + "extension": [ { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-TNMcpuPraefix", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/TNMcpuPraefixTCS", + "code": "c", + "display": "Kategorie wurde durch klinische Angaben festgestellt, bzw. erfüllt die Kriterien für p nicht" + } ] + } + } ], + "code": { + "coding": [ { + "system": "http://loinc.org", + "code": "21907-1", + "display": "Distant metastases.clinical [Class] Cancer" + } ] + }, + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/TNMMCS", + "code": "0", + "display": "0" + } ] + } + } ] + }, + "request": { + "method": "PUT", + "url": "Observation/fc7cabc6beffc1605c782aa46a8a32df94aa5ef01b9c828e0671e2a643d0a2bc" + } + }, { + "fullUrl": "Observation/555236ab41f9cc4e258c40c578b4ffbcb355055b8977706c983a3f338b6298b1", + "resource": { + "resourceType": "Observation", + "id": "555236ab41f9cc4e258c40c578b4ffbcb355055b8977706c983a3f338b6298b1", + "meta": { + "source": "UKER_ONKOSTAR.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Observation-TNMp" ] + }, + "status": "final", + "category": [ { + "coding": [ { + "system": "http://hl7.org/fhir/observation-category", + "code": "laboratory", + "display": "Laboratory" + } ] + } ], + "code": { + "coding": [ { + "system": "http://loinc.org", + "code": "21902-2", + "display": "Stage group.pathology Cancer" + } ] + }, + "subject": { + "reference": "Patient/cb07d6456df4982ff6b8de92fc018b0d5fc9dab1d1e303e97bd0474699111b52", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555999" + } + }, + "effectiveDateTime": "2021-11-05", + "component": [ { + "extension": [ { + "url": "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Extension-TNMcpuPraefix", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/TNMcpuPraefixTCS", + "code": "p", + "display": "Feststellung der Kategorie erfolgte durch eine pathohistologische Untersuchung, mit der auch der höchste Grad der jeweiligen Kategorie hätte festgestellt werden können" + } ] + } + } ], + "code": { + "coding": [ { + "system": "http://loinc.org", + "code": "21900-6", + "display": "Regional lymph nodes.pathology" + } ] + }, + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/TNMNCS", + "code": "2a", + "display": "2a" + } ] + } + } ] + }, + "request": { + "method": "PUT", + "url": "Observation/555236ab41f9cc4e258c40c578b4ffbcb355055b8977706c983a3f338b6298b1" + } + }, { + "fullUrl": "Observation/7b3181b44891bb7bba0f7ebb2511285589df40eb54a6073e390ed8550fc3ad8d", + "resource": { + "resourceType": "Observation", + "id": "7b3181b44891bb7bba0f7ebb2511285589df40eb54a6073e390ed8550fc3ad8d", + "meta": { + "source": "UKER_ONKOSTAR.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Observation-Fernmetastasen" ] + }, + "status": "final", + "category": [ { + "coding": [ { + "system": "http://hl7.org/fhir/observation-category", + "code": "laboratory", + "display": "Laboratory" + } ] + } ], + "code": { + "coding": [ { + "system": "http://loinc.org", + "code": "21907-1", + "display": "Distant metastases.clinical" + } ] + }, + "subject": { + "reference": "Patient/cb07d6456df4982ff6b8de92fc018b0d5fc9dab1d1e303e97bd0474699111b52", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555999" + } + }, + "effectiveDateTime": "2021-02-12", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/JNUCS", + "code": "J", + "display": "Ja" + } ] + }, + "bodySite": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/FMLokalisationCS", + "code": "OTH", + "display": "Andere Organe" + } ] + } + }, + "request": { + "method": "PUT", + "url": "Observation/7b3181b44891bb7bba0f7ebb2511285589df40eb54a6073e390ed8550fc3ad8d" + } + }, { + "fullUrl": "Observation/aa0f0ae0f151114fd167c207b9216685244dd8a17739f01e2e3fda9cada6491a", + "resource": { + "resourceType": "Observation", + "id": "aa0f0ae0f151114fd167c207b9216685244dd8a17739f01e2e3fda9cada6491a", + "meta": { + "source": "UKER_ONKOSTAR.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Observation-Fernmetastasen" ] + }, + "status": "final", + "category": [ { + "coding": [ { + "system": "http://hl7.org/fhir/observation-category", + "code": "laboratory", + "display": "Laboratory" + } ] + } ], + "code": { + "coding": [ { + "system": "http://loinc.org", + "code": "21907-1", + "display": "Distant metastases.clinical" + } ] + }, + "subject": { + "reference": "Patient/cb07d6456df4982ff6b8de92fc018b0d5fc9dab1d1e303e97bd0474699111b52", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555999" + } + }, + "effectiveDateTime": "2021-08-26", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/JNUCS", + "code": "J", + "display": "Ja" + } ] + }, + "bodySite": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/FMLokalisationCS", + "code": "OSS", + "display": "Knochen" + } ] + } + }, + "request": { + "method": "PUT", + "url": "Observation/aa0f0ae0f151114fd167c207b9216685244dd8a17739f01e2e3fda9cada6491a" + } + }, { + "fullUrl": "Observation/a0bac97bc3de3b565faba74d49c0b6eb43751b07fa5deda2f63b75eb8db66147", + "resource": { + "resourceType": "Observation", + "id": "a0bac97bc3de3b565faba74d49c0b6eb43751b07fa5deda2f63b75eb8db66147", + "meta": { + "source": "UKER_ONKOSTAR.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Observation-Fernmetastasen" ] + }, + "status": "final", + "category": [ { + "coding": [ { + "system": "http://hl7.org/fhir/observation-category", + "code": "laboratory", + "display": "Laboratory" + } ] + } ], + "code": { + "coding": [ { + "system": "http://loinc.org", + "code": "21907-1", + "display": "Distant metastases.clinical" + } ] + }, + "subject": { + "reference": "Patient/cb07d6456df4982ff6b8de92fc018b0d5fc9dab1d1e303e97bd0474699111b52", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555999" + } + }, + "effectiveDateTime": "2021-02-12", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/JNUCS", + "code": "J", + "display": "Ja" + } ] + }, + "bodySite": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/FMLokalisationCS", + "code": "OTH", + "display": "Andere Organe" + } ] + } + }, + "request": { + "method": "PUT", + "url": "Observation/a0bac97bc3de3b565faba74d49c0b6eb43751b07fa5deda2f63b75eb8db66147" + } + }, { + "fullUrl": "Observation/302e6b7f1b82d044c443cd186dad3eb3470351b10d6e0808fefcf9c99c354753", + "resource": { + "resourceType": "Observation", + "id": "302e6b7f1b82d044c443cd186dad3eb3470351b10d6e0808fefcf9c99c354753", + "meta": { + "source": "UKER_ONKOSTAR.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Observation-Fernmetastasen" ] + }, + "status": "final", + "category": [ { + "coding": [ { + "system": "http://hl7.org/fhir/observation-category", + "code": "laboratory", + "display": "Laboratory" + } ] + } ], + "code": { + "coding": [ { + "system": "http://loinc.org", + "code": "21907-1", + "display": "Distant metastases.clinical" + } ] + }, + "subject": { + "reference": "Patient/cb07d6456df4982ff6b8de92fc018b0d5fc9dab1d1e303e97bd0474699111b52", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555999" + } + }, + "effectiveDateTime": "2021-02-12", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/JNUCS", + "code": "J", + "display": "Ja" + } ] + }, + "bodySite": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/FMLokalisationCS", + "code": "HEP", + "display": "Leber" + } ] + } + }, + "request": { + "method": "PUT", + "url": "Observation/302e6b7f1b82d044c443cd186dad3eb3470351b10d6e0808fefcf9c99c354753" + } + }, { + "fullUrl": "Observation/734471546228b0e9385706399d6eeef9860ab8cb67536c07a0d9712d7bea302d", + "resource": { + "resourceType": "Observation", + "id": "734471546228b0e9385706399d6eeef9860ab8cb67536c07a0d9712d7bea302d", + "meta": { + "source": "UKER_ONKOSTAR.ONKOSTAR:obds-to-fhir:2.0.3", + "profile": [ "http://dktk.dkfz.de/fhir/StructureDefinition/onco-core-Observation-Fernmetastasen" ] + }, + "status": "final", + "category": [ { + "coding": [ { + "system": "http://hl7.org/fhir/observation-category", + "code": "laboratory", + "display": "Laboratory" + } ] + } ], + "code": { + "coding": [ { + "system": "http://loinc.org", + "code": "21907-1", + "display": "Distant metastases.clinical" + } ] + }, + "subject": { + "reference": "Patient/cb07d6456df4982ff6b8de92fc018b0d5fc9dab1d1e303e97bd0474699111b52", + "identifier": { + "type": { + "coding": [ { + "system": "http://terminology.hl7.org/CodeSystem/v2-0203", + "code": "MR" + } ] + }, + "system": "https://fhir.diz.uk-erlangen.de/identifiers/patient-id", + "value": "1055555999" + } + }, + "effectiveDateTime": "2021-02-12", + "valueCodeableConcept": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/JNUCS", + "code": "J", + "display": "Ja" + } ] + }, + "bodySite": { + "coding": [ { + "system": "http://dktk.dkfz.de/fhir/onco/core/CodeSystem/FMLokalisationCS", + "code": "LYM", + "display": "Lymphknoten" + } ] + } + }, + "request": { + "method": "PUT", + "url": "Observation/734471546228b0e9385706399d6eeef9860ab8cb67536c07a0d9712d7bea302d" + } + } ] +} diff --git a/src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsProcedureProcessorTest.mapProcedure_withGivenAdtXml.003_Pat1_Tumor1_Therapie1_Behandlungsende_OP.xml.approved.fhir.json b/src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsProcedureProcessorTest.mapProcedure_withGivenAdtXml.003_Pat1_Tumor1_Therapie1_Behandlungsende_OP.xml.approved.fhir.json index b54e788a..db5f3346 100644 --- a/src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsProcedureProcessorTest.mapProcedure_withGivenAdtXml.003_Pat1_Tumor1_Therapie1_Behandlungsende_OP.xml.approved.fhir.json +++ b/src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsProcedureProcessorTest.mapProcedure_withGivenAdtXml.003_Pat1_Tumor1_Therapie1_Behandlungsende_OP.xml.approved.fhir.json @@ -685,4 +685,4 @@ "url": "Procedure/b23a84e352ad4c3be35628c95c8daf97c5b9397d8e6cc61c5e50632a244307fd" } } ] -} \ No newline at end of file +} diff --git a/src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsProcedureProcessorTest.mapProcedure_withGivenAdtXml.007_Pat2_Tumor1_Behandlungsende_ST.xml.approved.fhir.json b/src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsProcedureProcessorTest.mapProcedure_withGivenAdtXml.007_Pat2_Tumor1_Behandlungsende_ST.xml.approved.fhir.json index 69b8d8a3..de7a4cb3 100644 --- a/src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsProcedureProcessorTest.mapProcedure_withGivenAdtXml.007_Pat2_Tumor1_Behandlungsende_ST.xml.approved.fhir.json +++ b/src/test/java/snapshots/org/miracum/streams/ume/obdstofhir/processor/ObdsProcedureProcessorTest.mapProcedure_withGivenAdtXml.007_Pat2_Tumor1_Behandlungsende_ST.xml.approved.fhir.json @@ -200,4 +200,4 @@ "url": "Procedure/5cc816ec84696364d264533059889822137ee92a943ad945eab1dbac304475ce" } } ] -} \ No newline at end of file +}