Class: DaVinciPASTestKit::DaVinciPASV201::ServerPasRequestBundleValidationTest
- Inherits:
-
Inferno::Test
- Object
- Inferno::Test
- DaVinciPASTestKit::DaVinciPASV201::ServerPasRequestBundleValidationTest
- Includes:
- PasBundleValidation
- Defined in:
- lib/davinci_pas_test_kit/generated/v2.0.1/pas_request_bundle/server_pas_request_bundle_validation_test.rb
Constant Summary
Constants included from PasBundleValidation
PasBundleValidation::CLAIM_INQUIRY_PROFILE, PasBundleValidation::CLAIM_INQUIRY_RESPONSE_PROFILE, PasBundleValidation::CLAIM_PROFILE, PasBundleValidation::CLAIM_RESPONSE_PROFILE
Constants included from ValidationTest
ValidationTest::DAR_CODE_SYSTEM_URL, ValidationTest::DAR_EXTENSION_URL
Instance Method Summary collapse
- #request_bundles ⇒ Object
- #request_type ⇒ Object
- #resource_type ⇒ Object
- #scratch_resources ⇒ Object
Methods included from PasBundleValidation
#absolute_url, #add_declared_profiles, #add_profile_to_instance, #add_resource_target_profile_to_map, #all_scratch_resources, #bundle_entry_map, #bundle_resources_target_profile_map, #check_presence_of_referenced_resources, #extract_base_url, #extract_profiles_to_validate_each_entry, #extract_resources_from_bundle, #find_profile_url, #find_referenced_instance_in_bundle, #generate_non_conformance_message, #handle_claim_profile, #metadata_map, #perform_request_validation, #perform_response_validation, #process_instance_profiles, #process_reference_element, #resource_present_in_pa_request_and_response_msg, #resource_shall_appear_once_message, #save_bundles_and_entries_to_scratch, #valid_url_or_urn_uuid?, #validate_bundle_entries_against_profiles, #validate_bundle_entries_full_url, #validate_pa_request_payload_structure, #validate_pa_response_body_structure, #validate_pas_bundle_json, #validate_resources_conformance_against_profile, #validate_uniqueness_of_supporting_info_sequences, #validation_error_messages
Methods included from ValidationTest
#check_for_dar, #check_for_dar_code, #check_for_dar_extension, #perform_validation_test
Instance Method Details
#request_bundles ⇒ Object
64 65 66 67 68 |
# File 'lib/davinci_pas_test_kit/generated/v2.0.1/pas_request_bundle/server_pas_request_bundle_validation_test.rb', line 64 def request_bundles parsed_payload = JSON.parse(pa_submit_request_payload) fhir_resources = [parsed_payload].flatten.compact.uniq.map { |payload| FHIR.from_contents(payload.to_json)}.compact fhir_resources.select { |res| res.resourceType == 'Bundle'} end |
#request_type ⇒ Object
60 61 62 |
# File 'lib/davinci_pas_test_kit/generated/v2.0.1/pas_request_bundle/server_pas_request_bundle_validation_test.rb', line 60 def request_type 'submit' end |
#resource_type ⇒ Object
52 53 54 |
# File 'lib/davinci_pas_test_kit/generated/v2.0.1/pas_request_bundle/server_pas_request_bundle_validation_test.rb', line 52 def resource_type 'Bundle' end |
#scratch_resources ⇒ Object
56 57 58 |
# File 'lib/davinci_pas_test_kit/generated/v2.0.1/pas_request_bundle/server_pas_request_bundle_validation_test.rb', line 56 def scratch_resources scratch[:submit_request_resources] ||= {} end |