From 1df42f083b851121d2a18c3bde53d65343a454a3 Mon Sep 17 00:00:00 2001 From: Pavel R Date: Tue, 19 Mar 2024 14:25:36 +0100 Subject: [PATCH] Temporary remove specimen checking Ref: https://github.com/hl7au/au-fhir-core-inferno/issues/18 --- .../diagnosticresult_path_must_support_test.rb | 1 - .../diagnosticresult_path_reference_resolution_test.rb | 1 - .../v0.3.0-ballot/diagnosticresult_path/metadata.yml | 5 ----- .../generated/v0.3.0-ballot/metadata.yml | 5 ----- .../generator/must_support_metadata_extractor.rb | 10 ++++++++++ 5 files changed, 10 insertions(+), 12 deletions(-) diff --git a/lib/au_core_test_kit/generated/v0.3.0-ballot/diagnosticresult_path/diagnosticresult_path_must_support_test.rb b/lib/au_core_test_kit/generated/v0.3.0-ballot/diagnosticresult_path/diagnosticresult_path_must_support_test.rb index ef882fa4..1df7eae3 100644 --- a/lib/au_core_test_kit/generated/v0.3.0-ballot/diagnosticresult_path/diagnosticresult_path_must_support_test.rb +++ b/lib/au_core_test_kit/generated/v0.3.0-ballot/diagnosticresult_path/diagnosticresult_path_must_support_test.rb @@ -28,7 +28,6 @@ class DiagnosticresultPathMustSupportTest < Inferno::Test * Observation.referenceRange.low * Observation.referenceRange.text * Observation.referenceRange.type - * Observation.specimen * Observation.status * Observation.subject * Observation.value[x] diff --git a/lib/au_core_test_kit/generated/v0.3.0-ballot/diagnosticresult_path/diagnosticresult_path_reference_resolution_test.rb b/lib/au_core_test_kit/generated/v0.3.0-ballot/diagnosticresult_path/diagnosticresult_path_reference_resolution_test.rb index 8517bdca..90729670 100644 --- a/lib/au_core_test_kit/generated/v0.3.0-ballot/diagnosticresult_path/diagnosticresult_path_reference_resolution_test.rb +++ b/lib/au_core_test_kit/generated/v0.3.0-ballot/diagnosticresult_path/diagnosticresult_path_reference_resolution_test.rb @@ -17,7 +17,6 @@ class DiagnosticresultPathReferenceResolutionTest < Inferno::Test * Observation.hasMember * Observation.performer - * Observation.specimen * Observation.subject ) diff --git a/lib/au_core_test_kit/generated/v0.3.0-ballot/diagnosticresult_path/metadata.yml b/lib/au_core_test_kit/generated/v0.3.0-ballot/diagnosticresult_path/metadata.yml index acf1aec3..086f3334 100644 --- a/lib/au_core_test_kit/generated/v0.3.0-ballot/diagnosticresult_path/metadata.yml +++ b/lib/au_core_test_kit/generated/v0.3.0-ballot/diagnosticresult_path/metadata.yml @@ -171,11 +171,6 @@ - :path: value[x] - :path: interpretation - :path: note - - :path: specimen - :types: - - Reference - :target_profiles: - - http://hl7.org.au/fhir/StructureDefinition/au-specimen - :path: referenceRange - :path: referenceRange.low - :path: referenceRange.high diff --git a/lib/au_core_test_kit/generated/v0.3.0-ballot/metadata.yml b/lib/au_core_test_kit/generated/v0.3.0-ballot/metadata.yml index 74fdb9a1..95f02ccf 100644 --- a/lib/au_core_test_kit/generated/v0.3.0-ballot/metadata.yml +++ b/lib/au_core_test_kit/generated/v0.3.0-ballot/metadata.yml @@ -1076,11 +1076,6 @@ - :path: value[x] - :path: interpretation - :path: note - - :path: specimen - :types: - - Reference - :target_profiles: - - http://hl7.org.au/fhir/StructureDefinition/au-specimen - :path: referenceRange - :path: referenceRange.low - :path: referenceRange.high diff --git a/lib/au_core_test_kit/generator/must_support_metadata_extractor.rb b/lib/au_core_test_kit/generator/must_support_metadata_extractor.rb index 4b1a18bb..47b59802 100644 --- a/lib/au_core_test_kit/generator/must_support_metadata_extractor.rb +++ b/lib/au_core_test_kit/generator/must_support_metadata_extractor.rb @@ -335,6 +335,7 @@ def handle_special_cases remove_observation_method_attribute remove_observation_value_attribute remove_lipid_result_attributes + remove_specimen_attribute case profile.version when '3.1.1' @@ -350,6 +351,15 @@ def handle_special_cases end end + def remove_specimen_attribute + # TODO: Temporary solution https://github.com/hl7au/au-fhir-core-inferno/issues/18 + if profile.id == 'au-core-diagnosticresult-path' + @must_supports[:elements].delete_if do |element| + ['specimen'].include? element[:path] + end + end + end + def remove_lipid_result_attributes # TODO: This code block should be discussed. # We need to understand why there are a lot of extra attributes