us_core_test_kit 0.6.0 → 0.6.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/us_core_test_kit/custom_groups/capability_statement/profile_support_test.rb +18 -16
- data/lib/us_core_test_kit/custom_groups/v3.1.1/capability_statement_group.rb +1 -1
- data/lib/us_core_test_kit/custom_groups/v3.1.1/profile_support_test.rb +51 -0
- data/lib/us_core_test_kit/custom_groups/v4.0.0/capability_statement_group.rb +1 -1
- data/lib/us_core_test_kit/custom_groups/v5.0.1/capability_statement_group.rb +1 -1
- data/lib/us_core_test_kit/custom_groups/v6.1.0/capability_statement_group.rb +1 -1
- data/lib/us_core_test_kit/generated/v3.1.1/allergy_intolerance/allergy_intolerance_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v3.1.1/bodyheight/bodyheight_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v3.1.1/bodytemp/bodytemp_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v3.1.1/bodyweight/bodyweight_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v3.1.1/bp/bp_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v3.1.1/care_plan/care_plan_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v3.1.1/care_team/care_team_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v3.1.1/condition/condition_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v3.1.1/device/device_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v3.1.1/diagnostic_report_lab/diagnostic_report_lab_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v3.1.1/diagnostic_report_note/diagnostic_report_note_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v3.1.1/document_reference/document_reference_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v3.1.1/encounter/encounter_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v3.1.1/goal/goal_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v3.1.1/head_circumference/head_circumference_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v3.1.1/heartrate/heartrate_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v3.1.1/immunization/immunization_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v3.1.1/medication_request/medication_request_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v3.1.1/observation_lab/observation_lab_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v3.1.1/pediatric_bmi_for_age/pediatric_bmi_for_age_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v3.1.1/pediatric_weight_for_height/pediatric_weight_for_height_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v3.1.1/procedure/procedure_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v3.1.1/provenance/provenance_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v3.1.1/pulse_oximetry/pulse_oximetry_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v3.1.1/resprate/resprate_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v3.1.1/smokingstatus/smokingstatus_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v4.0.0/allergy_intolerance/allergy_intolerance_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v4.0.0/blood_pressure/blood_pressure_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v4.0.0/bmi/bmi_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v4.0.0/body_height/body_height_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v4.0.0/body_temperature/body_temperature_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v4.0.0/body_weight/body_weight_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v4.0.0/care_plan/care_plan_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v4.0.0/care_team/care_team_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v4.0.0/condition/condition_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v4.0.0/device/device_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v4.0.0/diagnostic_report_lab/diagnostic_report_lab_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v4.0.0/diagnostic_report_note/diagnostic_report_note_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v4.0.0/document_reference/document_reference_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v4.0.0/encounter/encounter_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v4.0.0/goal/goal_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v4.0.0/head_circumference/head_circumference_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v4.0.0/head_circumference_percentile/head_circumference_percentile_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v4.0.0/heart_rate/heart_rate_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v4.0.0/immunization/immunization_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v4.0.0/medication_request/medication_request_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v4.0.0/observation_lab/observation_lab_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v4.0.0/pediatric_bmi_for_age/pediatric_bmi_for_age_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v4.0.0/pediatric_weight_for_height/pediatric_weight_for_height_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v4.0.0/procedure/procedure_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v4.0.0/provenance/provenance_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v4.0.0/pulse_oximetry/pulse_oximetry_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v4.0.0/respiratory_rate/respiratory_rate_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v4.0.0/smokingstatus/smokingstatus_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/allergy_intolerance/allergy_intolerance_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/blood_pressure/blood_pressure_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/bmi/bmi_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/body_height/body_height_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/body_temperature/body_temperature_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/body_weight/body_weight_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/care_plan/care_plan_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/care_team/care_team_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/condition_encounter_diagnosis/condition_encounter_diagnosis_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/condition_problems_health_concerns/condition_problems_health_concerns_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/device/device_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/diagnostic_report_lab/diagnostic_report_lab_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/diagnostic_report_note/diagnostic_report_note_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/document_reference/document_reference_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/encounter/encounter_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/goal/goal_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/head_circumference/head_circumference_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/head_circumference_percentile/head_circumference_percentile_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/heart_rate/heart_rate_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/immunization/immunization_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/medication_request/medication_request_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/observation_clinical_test/observation_clinical_test_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/observation_imaging/observation_imaging_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/observation_lab/observation_lab_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/observation_sdoh_assessment/observation_sdoh_assessment_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/observation_sexual_orientation/observation_sexual_orientation_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/observation_social_history/observation_social_history_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/pediatric_bmi_for_age/pediatric_bmi_for_age_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/pediatric_weight_for_height/pediatric_weight_for_height_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/procedure/procedure_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/provenance/provenance_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/pulse_oximetry/pulse_oximetry_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/questionnaire_response/questionnaire_response_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/related_person/related_person_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/respiratory_rate/respiratory_rate_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/service_request/service_request_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v5.0.1/smokingstatus/smokingstatus_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/allergy_intolerance/allergy_intolerance_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/blood_pressure/blood_pressure_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/bmi/bmi_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/body_height/body_height_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/body_temperature/body_temperature_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/body_weight/body_weight_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/care_plan/care_plan_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/care_team/care_team_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/condition_encounter_diagnosis/condition_encounter_diagnosis_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/condition_problems_health_concerns/condition_problems_health_concerns_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/coverage/coverage_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/device/device_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/diagnostic_report_lab/diagnostic_report_lab_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/diagnostic_report_note/diagnostic_report_note_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/document_reference/document_reference_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/encounter/encounter_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/goal/goal_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/head_circumference/head_circumference_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/head_circumference_percentile/head_circumference_percentile_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/heart_rate/heart_rate_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/immunization/immunization_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/medication_dispense/medication_dispense_patient_search_test.rb +2 -2
- data/lib/us_core_test_kit/generated/v6.1.0/medication_dispense/medication_dispense_patient_status_search_test.rb +2 -2
- data/lib/us_core_test_kit/generated/v6.1.0/medication_dispense/medication_dispense_patient_status_type_search_test.rb +2 -2
- data/lib/us_core_test_kit/generated/v6.1.0/medication_dispense/medication_dispense_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/medication_request/medication_request_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/observation_clinical_result/observation_clinical_result_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/observation_lab/observation_lab_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/observation_occupation/observation_occupation_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/observation_pregnancyintent/observation_pregnancyintent_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/observation_pregnancystatus/observation_pregnancystatus_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/observation_screening_assessment/observation_screening_assessment_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/observation_sexual_orientation/observation_sexual_orientation_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/pediatric_bmi_for_age/pediatric_bmi_for_age_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/pediatric_weight_for_height/pediatric_weight_for_height_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/procedure/procedure_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/provenance/provenance_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/pulse_oximetry/pulse_oximetry_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/questionnaire_response/questionnaire_response_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/related_person/related_person_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/respiratory_rate/respiratory_rate_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/service_request/service_request_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/simple_observation/simple_observation_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/smokingstatus/smokingstatus_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generated/v6.1.0/specimen/specimen_reference_resolution_test.rb +0 -2
- data/lib/us_core_test_kit/generator/group_metadata_extractor.rb +0 -1
- data/lib/us_core_test_kit/generator/ig_loader.rb +2 -0
- data/lib/us_core_test_kit/generator/search_test_generator.rb +2 -2
- data/lib/us_core_test_kit/generator.rb +0 -6
- data/lib/us_core_test_kit/search_test.rb +29 -7
- data/lib/us_core_test_kit/version.rb +1 -1
- metadata +3 -7
- data/lib/us_core_test_kit/generated/v3.1.1/resource_list.rb +0 -28
- data/lib/us_core_test_kit/generated/v4.0.0/resource_list.rb +0 -28
- data/lib/us_core_test_kit/generated/v5.0.1/resource_list.rb +0 -31
- data/lib/us_core_test_kit/generated/v6.1.0/resource_list.rb +0 -34
- data/lib/us_core_test_kit/generator/resource_list_generator.rb +0 -42
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 68ac411f63c86114f8a144f0e16768ac116b09cc8bf4c7568af12f2e223e17e0
|
4
|
+
data.tar.gz: '08e4599ff6099d98ab78b463d04100edcf4cc662f51a89f386801f598cd9138c'
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f9317e5e66be91e6ff8b6ad3c021fd245221fe6ec3ab6ec5cb78a193b1913371653aed09b7fdeec9db3373ab79d9e757e858b284b44016839c0430de3b42d6da
|
7
|
+
data.tar.gz: ca64fa89537af72ddf5ae092e89f40abb867549c228b47596983b3efdbe1551330e4c9375fe5ad3eced41f6839e02443554b2326d89f0b1c29ee0c2ea94298ea
|
@@ -20,30 +20,32 @@ module USCoreTestKit
|
|
20
20
|
assert_resource_type(:capability_statement)
|
21
21
|
capability_statement = resource
|
22
22
|
|
23
|
-
|
23
|
+
supported_profiles =
|
24
24
|
capability_statement.rest
|
25
|
-
&.each_with_object([]) do |rest,
|
26
|
-
rest.resource.each { |resource|
|
25
|
+
&.each_with_object([]) do |rest, profiles|
|
26
|
+
rest.resource.each { |resource| profiles.concat(resource.supportedProfile) }
|
27
27
|
end.uniq
|
28
28
|
|
29
|
-
assert
|
29
|
+
assert supported_profiles.include?('http://hl7.org/fhir/us/core/StructureDefinition/us-core-patient'), 'US Core Patient profile not supported'
|
30
30
|
|
31
|
-
|
31
|
+
us_core_profiles = config.options[:us_core_profiles]
|
32
32
|
|
33
|
-
|
34
|
-
|
35
|
-
assert
|
33
|
+
other_profiles = us_core_profiles.reject { |resource_type| resource_type == 'http://hl7.org/fhir/us/core/StructureDefinition/us-core-patient' }
|
34
|
+
other_profiles_supported = other_profiles.any? { |profile| supported_profiles.include? profile }
|
35
|
+
assert other_profiles_supported, 'No US Core profiles other than Patient are supported'
|
36
36
|
|
37
|
-
if config.options[:
|
38
|
-
|
37
|
+
if config.options[:required_profiles].present?
|
38
|
+
required_profiles = config.options[:required_profiles]
|
39
39
|
|
40
|
-
|
41
|
-
missing_resources
|
42
|
-
.map { |resource| "`#{resource}`" }
|
43
|
-
.join(', ')
|
40
|
+
missing_profiles = required_profiles - supported_profiles
|
44
41
|
|
45
|
-
|
46
|
-
|
42
|
+
missing_profiles_list =
|
43
|
+
missing_profiles
|
44
|
+
.map { |resource| "`#{resource}`" }
|
45
|
+
.join(', ')
|
46
|
+
|
47
|
+
assert missing_profiles.empty?,
|
48
|
+
"The CapabilityStatement did not list support for the following resources: #{missing_profiles_list}"
|
47
49
|
end
|
48
50
|
end
|
49
51
|
end
|
@@ -2,7 +2,7 @@ require 'tls_test_kit'
|
|
2
2
|
require_relative '../capability_statement/conformance_support_test'
|
3
3
|
require_relative '../capability_statement/fhir_version_test'
|
4
4
|
require_relative '../capability_statement/json_support_test'
|
5
|
-
require_relative '
|
5
|
+
require_relative './profile_support_test'
|
6
6
|
|
7
7
|
module USCoreTestKit
|
8
8
|
module USCoreV311
|
@@ -0,0 +1,51 @@
|
|
1
|
+
module USCoreTestKit
|
2
|
+
module USCoreV311
|
3
|
+
class ProfileSupportTest < Inferno::Test
|
4
|
+
id :us_core_profile_support
|
5
|
+
title 'Capability Statement lists support for required US Core Resoruce Types'
|
6
|
+
description %(
|
7
|
+
The US Core Implementation Guide states:
|
8
|
+
|
9
|
+
```
|
10
|
+
The US Core Server SHALL:
|
11
|
+
1. Support the US Core Patient resource.
|
12
|
+
2. Support at least one additional US Core resources.
|
13
|
+
|
14
|
+
In order to support USCDI, servers must support all USCDI resources.
|
15
|
+
```
|
16
|
+
)
|
17
|
+
uses_request :capability_statement
|
18
|
+
|
19
|
+
run do
|
20
|
+
assert_resource_type(:capability_statement)
|
21
|
+
capability_statement = resource
|
22
|
+
|
23
|
+
supported_resources =
|
24
|
+
capability_statement.rest
|
25
|
+
&.each_with_object([]) do |rest, resources|
|
26
|
+
rest.resource.each { |resource| resources << resource.type }
|
27
|
+
end.uniq
|
28
|
+
|
29
|
+
assert supported_resources.include?('Patient'), 'US Core Patient profile not supported'
|
30
|
+
|
31
|
+
us_core_resources = config.options[:us_core_resources]
|
32
|
+
|
33
|
+
other_resources = us_core_resources.reject { |resource_type| resource_type == 'Patient' }
|
34
|
+
other_resources_supported = other_resources.any? { |resource| supported_resources.include? resource }
|
35
|
+
assert other_resources_supported, 'No US Core resources other than Patient are supported'
|
36
|
+
|
37
|
+
if config.options[:required_resources].present?
|
38
|
+
missing_resources = config.options[:required_resources] - supported_resources
|
39
|
+
|
40
|
+
missing_resource_list =
|
41
|
+
missing_resources
|
42
|
+
.map { |resource| "`#{resource}`" }
|
43
|
+
.join(', ')
|
44
|
+
|
45
|
+
assert missing_resources.empty?,
|
46
|
+
"The CapabilityStatement did not list support for the following resources: #{missing_resource_list}"
|
47
|
+
end
|
48
|
+
end
|
49
|
+
end
|
50
|
+
end
|
51
|
+
end
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV311
|
6
5
|
class AllergyIntoleranceReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within AllergyIntolerance resources are valid'
|
11
9
|
description %(
|
data/lib/us_core_test_kit/generated/v3.1.1/bodyheight/bodyheight_reference_resolution_test.rb
CHANGED
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV311
|
6
5
|
class BodyheightReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within Observation resources are valid'
|
11
9
|
description %(
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV311
|
6
5
|
class BodytempReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within Observation resources are valid'
|
11
9
|
description %(
|
data/lib/us_core_test_kit/generated/v3.1.1/bodyweight/bodyweight_reference_resolution_test.rb
CHANGED
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV311
|
6
5
|
class BodyweightReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within Observation resources are valid'
|
11
9
|
description %(
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV311
|
6
5
|
class BpReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within Observation resources are valid'
|
11
9
|
description %(
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV311
|
6
5
|
class CarePlanReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within CarePlan resources are valid'
|
11
9
|
description %(
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV311
|
6
5
|
class CareTeamReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within CareTeam resources are valid'
|
11
9
|
description %(
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV311
|
6
5
|
class ConditionReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within Condition resources are valid'
|
11
9
|
description %(
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV311
|
6
5
|
class DeviceReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within Device resources are valid'
|
11
9
|
description %(
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV311
|
6
5
|
class DiagnosticReportLabReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within DiagnosticReport resources are valid'
|
11
9
|
description %(
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV311
|
6
5
|
class DiagnosticReportNoteReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within DiagnosticReport resources are valid'
|
11
9
|
description %(
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV311
|
6
5
|
class DocumentReferenceReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within DocumentReference resources are valid'
|
11
9
|
description %(
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV311
|
6
5
|
class EncounterReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within Encounter resources are valid'
|
11
9
|
description %(
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV311
|
6
5
|
class GoalReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within Goal resources are valid'
|
11
9
|
description %(
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV311
|
6
5
|
class HeadCircumferenceReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within Observation resources are valid'
|
11
9
|
description %(
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV311
|
6
5
|
class HeartrateReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within Observation resources are valid'
|
11
9
|
description %(
|
data/lib/us_core_test_kit/generated/v3.1.1/immunization/immunization_reference_resolution_test.rb
CHANGED
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV311
|
6
5
|
class ImmunizationReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within Immunization resources are valid'
|
11
9
|
description %(
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV311
|
6
5
|
class MedicationRequestReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within MedicationRequest resources are valid'
|
11
9
|
description %(
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV311
|
6
5
|
class ObservationLabReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within Observation resources are valid'
|
11
9
|
description %(
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV311
|
6
5
|
class PediatricBmiForAgeReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within Observation resources are valid'
|
11
9
|
description %(
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV311
|
6
5
|
class PediatricWeightForHeightReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within Observation resources are valid'
|
11
9
|
description %(
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV311
|
6
5
|
class ProcedureReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within Procedure resources are valid'
|
11
9
|
description %(
|
data/lib/us_core_test_kit/generated/v3.1.1/provenance/provenance_reference_resolution_test.rb
CHANGED
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV311
|
6
5
|
class ProvenanceReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within Provenance resources are valid'
|
11
9
|
description %(
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV311
|
6
5
|
class PulseOximetryReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within Observation resources are valid'
|
11
9
|
description %(
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV311
|
6
5
|
class ResprateReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within Observation resources are valid'
|
11
9
|
description %(
|
data/lib/us_core_test_kit/generated/v3.1.1/smokingstatus/smokingstatus_reference_resolution_test.rb
CHANGED
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV311
|
6
5
|
class SmokingstatusReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within Observation resources are valid'
|
11
9
|
description %(
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV400
|
6
5
|
class AllergyIntoleranceReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within AllergyIntolerance resources are valid'
|
11
9
|
description %(
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV400
|
6
5
|
class BloodPressureReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within Observation resources are valid'
|
11
9
|
description %(
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV400
|
6
5
|
class BmiReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within Observation resources are valid'
|
11
9
|
description %(
|
data/lib/us_core_test_kit/generated/v4.0.0/body_height/body_height_reference_resolution_test.rb
CHANGED
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV400
|
6
5
|
class BodyHeightReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within Observation resources are valid'
|
11
9
|
description %(
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV400
|
6
5
|
class BodyTemperatureReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within Observation resources are valid'
|
11
9
|
description %(
|
data/lib/us_core_test_kit/generated/v4.0.0/body_weight/body_weight_reference_resolution_test.rb
CHANGED
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV400
|
6
5
|
class BodyWeightReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within Observation resources are valid'
|
11
9
|
description %(
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV400
|
6
5
|
class CarePlanReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within CarePlan resources are valid'
|
11
9
|
description %(
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV400
|
6
5
|
class CareTeamReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within CareTeam resources are valid'
|
11
9
|
description %(
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV400
|
6
5
|
class ConditionReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within Condition resources are valid'
|
11
9
|
description %(
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV400
|
6
5
|
class DeviceReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within Device resources are valid'
|
11
9
|
description %(
|
@@ -1,11 +1,9 @@
|
|
1
1
|
require_relative '../../../reference_resolution_test'
|
2
|
-
require_relative '../resource_list'
|
3
2
|
|
4
3
|
module USCoreTestKit
|
5
4
|
module USCoreV400
|
6
5
|
class DiagnosticReportLabReferenceResolutionTest < Inferno::Test
|
7
6
|
include USCoreTestKit::ReferenceResolutionTest
|
8
|
-
include ResourceList
|
9
7
|
|
10
8
|
title 'MustSupport references within DiagnosticReport resources are valid'
|
11
9
|
description %(
|