diff --git a/org.hl7.fhir.convertors/pom.xml b/org.hl7.fhir.convertors/pom.xml index 967ffb2e6..b6f881489 100644 --- a/org.hl7.fhir.convertors/pom.xml +++ b/org.hl7.fhir.convertors/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 3.7.29-SNAPSHOT + 3.7.30-SNAPSHOT ../pom.xml diff --git a/org.hl7.fhir.dstu2/pom.xml b/org.hl7.fhir.dstu2/pom.xml index c1500808e..c92423117 100644 --- a/org.hl7.fhir.dstu2/pom.xml +++ b/org.hl7.fhir.dstu2/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 3.7.29-SNAPSHOT + 3.7.30-SNAPSHOT ../pom.xml diff --git a/org.hl7.fhir.dstu2016may/pom.xml b/org.hl7.fhir.dstu2016may/pom.xml index ef32a55b9..df1c550ff 100644 --- a/org.hl7.fhir.dstu2016may/pom.xml +++ b/org.hl7.fhir.dstu2016may/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 3.7.29-SNAPSHOT + 3.7.30-SNAPSHOT ../pom.xml diff --git a/org.hl7.fhir.dstu3/pom.xml b/org.hl7.fhir.dstu3/pom.xml index a7fec192a..55fd10a04 100644 --- a/org.hl7.fhir.dstu3/pom.xml +++ b/org.hl7.fhir.dstu3/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 3.7.29-SNAPSHOT + 3.7.30-SNAPSHOT ../pom.xml diff --git a/org.hl7.fhir.r4/pom.xml b/org.hl7.fhir.r4/pom.xml index 36bd35a7c..522d95392 100644 --- a/org.hl7.fhir.r4/pom.xml +++ b/org.hl7.fhir.r4/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 3.7.29-SNAPSHOT + 3.7.30-SNAPSHOT ../pom.xml diff --git a/org.hl7.fhir.r5/pom.xml b/org.hl7.fhir.r5/pom.xml index 1e3cb691e..2afdd98f6 100644 --- a/org.hl7.fhir.r5/pom.xml +++ b/org.hl7.fhir.r5/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 3.7.29-SNAPSHOT + 3.7.30-SNAPSHOT ../pom.xml diff --git a/org.hl7.fhir.utilities/pom.xml b/org.hl7.fhir.utilities/pom.xml index 5a2563e20..dc15c7a91 100644 --- a/org.hl7.fhir.utilities/pom.xml +++ b/org.hl7.fhir.utilities/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 3.7.29-SNAPSHOT + 3.7.30-SNAPSHOT ../pom.xml diff --git a/org.hl7.fhir.validation.cli/pom.xml b/org.hl7.fhir.validation.cli/pom.xml index 6a54727d7..827839ed7 100644 --- a/org.hl7.fhir.validation.cli/pom.xml +++ b/org.hl7.fhir.validation.cli/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 3.7.29-SNAPSHOT + 3.7.30-SNAPSHOT ../pom.xml diff --git a/org.hl7.fhir.validation/pom.xml b/org.hl7.fhir.validation/pom.xml index 27cbca8bf..57b6e2e53 100644 --- a/org.hl7.fhir.validation/pom.xml +++ b/org.hl7.fhir.validation/pom.xml @@ -5,7 +5,7 @@ ca.uhn.hapi.fhir org.hl7.fhir.core - 3.7.29-SNAPSHOT + 3.7.30-SNAPSHOT ../pom.xml diff --git a/org.hl7.fhir.validation/src/main/java/org/hl7/fhir/r5/validation/InstanceValidator.java b/org.hl7.fhir.validation/src/main/java/org/hl7/fhir/r5/validation/InstanceValidator.java index 82cc9ad70..fcd1ca15e 100644 --- a/org.hl7.fhir.validation/src/main/java/org/hl7/fhir/r5/validation/InstanceValidator.java +++ b/org.hl7.fhir.validation/src/main/java/org/hl7/fhir/r5/validation/InstanceValidator.java @@ -3816,7 +3816,9 @@ private boolean isAnswerRequirementFulfilled(QuestionnaireItemComponent qItem, L if (isPrimitiveType(type)) { checkPrimitive(hostContext, errors, ei.path, type, ei.definition, ei.element, profile); } else { -// checkNonPrimitive(appContext, errors, ei.path, type, ei.definition, ei.element, profile); + if (ei.definition.hasFixed()) { + checkFixedValue(errors,ei.path, ei.element, ei.definition.getFixed(), ei.definition.getSliceName(), null); + } } if (type.equals("Identifier")) { checkIdentifier(errors, ei.path, ei.element, ei.definition); @@ -3833,7 +3835,7 @@ private boolean isAnswerRequirementFulfilled(QuestionnaireItemComponent qItem, L } else if (type.equals("Resource")) { validateContains(hostContext, errors, ei.path, ei.definition, definition, resource, ei.element, localStack, idStatusForEntry(element, ei)); // if // (str.matches(".*([.,/])work\\1$")) - } + } } else { if (rule(errors, IssueType.STRUCTURE, ei.line(), ei.col(), stack.getLiteralPath(), ei.definition != null, "Unrecognised Content " + ei.name)) validateElement(hostContext, errors, profile, ei.definition, null, null, resource, ei.element, type, localStack, false); diff --git a/org.hl7.fhir.validation/src/test/resources/validation-examples/manifest.json b/org.hl7.fhir.validation/src/test/resources/validation-examples/manifest.json index 9cf72caba..526495352 100644 --- a/org.hl7.fhir.validation/src/test/resources/validation-examples/manifest.json +++ b/org.hl7.fhir.validation/src/test/resources/validation-examples/manifest.json @@ -467,6 +467,21 @@ "source" : "extension-slice-profile.xml", "errorCount": 0 } + }, + "observation-cholesterol-good.xml" : { + "errorCount": 0 + }, + "observation-cholesterol-bad-referencerangemissing.xml" : { + "errorCount": 1, + "errors": ["ERROR: Observation: Profile http://hl7.org/fhir/StructureDefinition/cholesterol, Element 'Observation.referenceRange': minimum required = 1, but only found 0"] + }, + "observation-cholesterol-bad-referencerangehighfixedquantitywrong.xml" : { + "errorCount": 1, + "errors": ["ERROR: Observation.referenceRange.high.value: Value is '0' but must be '4.5'"] + }, + "observation-cholesterol-bad-wrongcode.xml" : { + "errorCount": 2, + "errors": ["ERROR: Observation.code.coding.code: Value is '13457-7' but must be '35200-5'","ERROR: Observation.code.coding.display: Value is 'Cholesterol in LDL [Mass/volume] in Serum or Plasma by calculation' but must be 'Cholesterol [Moles/?volume] in Serum or Plasma'"] } } } diff --git a/org.hl7.fhir.validation/src/test/resources/validation-examples/observation-cholesterol-bad-referencerangehighfixedquantitywrong.xml b/org.hl7.fhir.validation/src/test/resources/validation-examples/observation-cholesterol-bad-referencerangehighfixedquantitywrong.xml new file mode 100644 index 000000000..09eba07e4 --- /dev/null +++ b/org.hl7.fhir.validation/src/test/resources/validation-examples/observation-cholesterol-bad-referencerangehighfixedquantitywrong.xml @@ -0,0 +1,98 @@ + + + + + + + + +
+

+ Generated Narrative with Details +

+

+ id + : cholesterol +

+

+ status + : final +

+

+ code + : Cholesterol + (Details : {LOINC code '35200-5' = 'Cholesterol [Mass or + Moles/volume] in Serum or Plasma', + given as 'Cholesterol + [Moles/​volume] in Serum or Plasma'}) + +

+

+ subject + : + Patient/pat2 +

+

+ performer + : + Acme Laboratory, Inc +

+

+ value + : 6.3 mmol/L + (Details: UCUM code mmol/L = 'mmol/L') +

+

ReferenceRanges

+ + + + + + + + + +
- + High +
* + 4.5 mmol/L + (Details: UCUM code mmol/L = 'mmol/L') +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
\ No newline at end of file diff --git a/org.hl7.fhir.validation/src/test/resources/validation-examples/observation-cholesterol-bad-referencerangemissing.xml b/org.hl7.fhir.validation/src/test/resources/validation-examples/observation-cholesterol-bad-referencerangemissing.xml new file mode 100644 index 000000000..b4c898ec6 --- /dev/null +++ b/org.hl7.fhir.validation/src/test/resources/validation-examples/observation-cholesterol-bad-referencerangemissing.xml @@ -0,0 +1,92 @@ + + + + + + + + +
+

+ Generated Narrative with Details +

+

+ id + : cholesterol +

+

+ status + : final +

+

+ code + : Cholesterol + (Details : {LOINC code '35200-5' = 'Cholesterol [Mass or + Moles/volume] in Serum or Plasma', + given as 'Cholesterol + [Moles/​volume] in Serum or Plasma'}) + +

+

+ subject + : + Patient/pat2 +

+

+ performer + : + Acme Laboratory, Inc +

+

+ value + : 6.3 mmol/L + (Details: UCUM code mmol/L = 'mmol/L') +

+

ReferenceRanges

+ + + + + + + + + +
- + High +
* + 4.5 mmol/L + (Details: UCUM code mmol/L = 'mmol/L') +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + +
\ No newline at end of file diff --git a/org.hl7.fhir.validation/src/test/resources/validation-examples/observation-cholesterol-bad-wrongcode.xml b/org.hl7.fhir.validation/src/test/resources/validation-examples/observation-cholesterol-bad-wrongcode.xml new file mode 100644 index 000000000..e95ab4b5c --- /dev/null +++ b/org.hl7.fhir.validation/src/test/resources/validation-examples/observation-cholesterol-bad-wrongcode.xml @@ -0,0 +1,100 @@ + + + + + + + + +
+

+ Generated Narrative with Details +

+

+ id + : cholesterol +

+

+ status + : final +

+

+ code + : Cholesterol + (Details : {LOINC code '35200-5' = 'Cholesterol [Mass or + Moles/volume] in Serum or Plasma', + given as 'Cholesterol + [Moles/​volume] in Serum or Plasma'}) + +

+

+ subject + : + Patient/pat2 +

+

+ performer + : + Acme Laboratory, Inc +

+

+ value + : 6.3 mmol/L + (Details: UCUM code mmol/L = 'mmol/L') +

+

ReferenceRanges

+ + + + + + + + + +
- + High +
* + 4.5 mmol/L + (Details: UCUM code mmol/L = 'mmol/L') +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
\ No newline at end of file diff --git a/org.hl7.fhir.validation/src/test/resources/validation-examples/observation-cholesterol-good.xml b/org.hl7.fhir.validation/src/test/resources/validation-examples/observation-cholesterol-good.xml new file mode 100644 index 000000000..b4b36c75f --- /dev/null +++ b/org.hl7.fhir.validation/src/test/resources/validation-examples/observation-cholesterol-good.xml @@ -0,0 +1,97 @@ + + + + + + + + +
+

+ Generated Narrative with Details +

+

+ id + : cholesterol +

+

+ status + : final +

+

+ code + : Cholesterol + (Details : {LOINC code '35200-5' = 'Cholesterol [Mass or + Moles/volume] in Serum or Plasma', + given as 'Cholesterol + [Moles/​volume] in Serum or Plasma'}) + +

+

+ subject + : + Patient/pat2 +

+

+ performer + : + Acme Laboratory, Inc +

+

+ value + : 6.3 mmol/L + (Details: UCUM code mmol/L = 'mmol/L') +

+

ReferenceRanges

+ + + + + + + + + +
- + High +
* + 4.5 mmol/L + (Details: UCUM code mmol/L = 'mmol/L') +
+
+
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
\ No newline at end of file diff --git a/pom.xml b/pom.xml index 7c0ab864e..1494558bc 100644 --- a/pom.xml +++ b/pom.xml @@ -13,7 +13,7 @@ each other. It is fine to bump the point version of this POM without affecting HAPI FHIR. --> - 3.7.29-SNAPSHOT + 3.7.30-SNAPSHOT 3.7.0-SNAPSHOT diff --git a/release.bat b/release.bat index ed62cdebe..e54cea6bb 100644 --- a/release.bat +++ b/release.bat @@ -4,16 +4,18 @@ REM make sure you are committed echo echo =============================================================== -echo upgrade and release fhir.core from 3.7.28-SNAPSHOT to 3.7.29-SNAPSHOT +echo upgrade and release fhir.core from 3.7.29-SNAPSHOT to 3.7.30-SNAPSHOT echo =============================================================== pause -call mvn versions:set -DnewVersion=3.7.29-SNAPSHOT +call mvn versions:set -DnewVersion=3.7.30-SNAPSHOT call git commit -a -m "Release new version" call git push origin master -call "C:\tools\fnr.exe" --cl --dir "C:\work\org.hl7.fhir\build" --fileMask "*.java" --excludeFileMask "*.dll, *.exe" --includeSubDirectories --find "3.7.28-SNAPSHOT" --replace "3.7.29-SNAPSHOT" -call "C:\tools\fnr.exe" --cl --dir "C:\work\org.hl7.fhir\build" --fileMask "*.xml" --excludeFileMask "*.dll, *.exe" --find "3.7.28-SNAPSHOT" --replace "3.7.29-SNAPSHOT" +call "C:\tools\fnr.exe" --cl --dir "C:\work\org.hl7.fhir\build" --fileMask "*.java" --includeSubDirectories --find "3.7.29-SNAPSHOT" --replace "3.7.30-SNAPSHOT" +call "C:\tools\fnr.exe" --cl --dir "C:\work\org.hl7.fhir\fhir-ig-publisher" --fileMask "*.xml" --includeSubDirectories --find "3.7.29-SNAPSHOT" --replace "3.7.30-SNAPSHOT" +call "C:\tools\fnr.exe" --cl --dir "C:\work\org.hl7.fhir\build" --fileMask "*.xml" --find "3.7.29-SNAPSHOT" --replace "3.7.30-SNAPSHOT" call mvn deploy +call python c:\tools\zulip-api\zulip\zulip\send.py --stream committers/notification --subject "java core" -m "New Java Core v3.7.30-SNAPSHOT released." --config-file zuliprc echo =============================================================== echo all done