Class: DaVinciPASTestKit::DaVinciPASV201::PasClientMustSupportRequirementTest
- Inherits:
-
Inferno::Test
- Object
- Inferno::Test
- DaVinciPASTestKit::DaVinciPASV201::PasClientMustSupportRequirementTest
show all
- Includes:
- MustSupportTest
- Defined in:
- lib/davinci_pas_test_kit/custom_groups/v2.0.1/must_support/pas_client_must_support_requirement_test.rb
Constant Summary
FHIRResourceNavigation::DAR_EXTENSION_URL
Instance Attribute Summary collapse
Class Method Summary
collapse
Instance Method Summary
collapse
#all_must_support_errors, #perform_must_support_test, #reset_variables, #tagged_resources, #validate_must_support
#find_a_value_at, #get_next_value, #resolve_path
Instance Attribute Details
#resource_type ⇒ Object
Returns the value of attribute resource_type.
9
10
11
|
# File 'lib/davinci_pas_test_kit/custom_groups/v2.0.1/must_support/pas_client_must_support_requirement_test.rb', line 9
def resource_type
@resource_type
end
|
Class Method Details
81
82
83
84
85
|
# File 'lib/davinci_pas_test_kit/custom_groups/v2.0.1/must_support/pas_client_must_support_requirement_test.rb', line 81
def self.metadata
metadata_file_name = "#{@@resource_type.underscore}_metadata.yml"
Generator::GroupMetadata.new(YAML.load_file(File.join(__dir__, metadata_file_name),
aliases: true))
end
|
Instance Method Details
#all_scratch_resources ⇒ Object
91
92
93
|
# File 'lib/davinci_pas_test_kit/custom_groups/v2.0.1/must_support/pas_client_must_support_requirement_test.rb', line 91
def all_scratch_resources
scratch_resources[:all] ||= []
end
|
#grouped_resources ⇒ Object
100
101
102
|
# File 'lib/davinci_pas_test_kit/custom_groups/v2.0.1/must_support/pas_client_must_support_requirement_test.rb', line 100
def grouped_resources
resources_of_interest.group_by(&:resourceType)
end
|
#resource_types ⇒ Object
77
78
79
|
# File 'lib/davinci_pas_test_kit/custom_groups/v2.0.1/must_support/pas_client_must_support_requirement_test.rb', line 77
def resource_types
['DeviceRequest', 'MedicationRequest', 'NutritionOrder', 'ServiceRequest']
end
|
#resources_of_interest ⇒ Object
95
96
97
98
|
# File 'lib/davinci_pas_test_kit/custom_groups/v2.0.1/must_support/pas_client_must_support_requirement_test.rb', line 95
def resources_of_interest
collection = tagged_resources(SUBMIT_TAG).presence || all_scratch_resources
collection.select { |resource| resource_types.include?(resource.resourceType) }
end
|
#scratch_resources ⇒ Object
87
88
89
|
# File 'lib/davinci_pas_test_kit/custom_groups/v2.0.1/must_support/pas_client_must_support_requirement_test.rb', line 87
def scratch_resources
scratch[:submit_request_resources] ||= {}
end
|