davinci_pas_test_kit 0.12.0 → 0.12.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (51) hide show
  1. checksums.yaml +4 -4
  2. data/lib/davinci_pas_test_kit/client_suite.rb +24 -0
  3. data/lib/davinci_pas_test_kit/custom_groups/v2.0.1/client_tests/pas_client_approval_submit_test.rb +29 -1
  4. data/lib/davinci_pas_test_kit/custom_groups/v2.0.1/client_tests/pas_client_denial_submit_test.rb +27 -4
  5. data/lib/davinci_pas_test_kit/{generated/v2.0.1/client_tests/client_pended_pas_inquiry_request_bundle_validation_test.rb → custom_groups/v2.0.1/client_tests/pas_client_inquire_request_bundle_validation_test.rb} +22 -20
  6. data/lib/davinci_pas_test_kit/{generated/v2.0.1/client_tests/client_denial_pas_response_bundle_validation_test.rb → custom_groups/v2.0.1/client_tests/pas_client_inquire_response_bundle_validation_test.rb} +34 -21
  7. data/lib/davinci_pas_test_kit/custom_groups/v2.0.1/client_tests/pas_client_pended_submit_test.rb +124 -5
  8. data/lib/davinci_pas_test_kit/{generated/v2.0.1/client_tests/client_pas_request_bundle_validation_test.rb → custom_groups/v2.0.1/client_tests/pas_client_request_bundle_validation_test.rb} +22 -20
  9. data/lib/davinci_pas_test_kit/custom_groups/v2.0.1/client_tests/{pas_client_approval_submit_response_attest.rb → pas_client_response_attest.rb} +26 -9
  10. data/lib/davinci_pas_test_kit/{generated/v2.0.1/client_tests/client_pended_pas_response_bundle_validation_test.rb → custom_groups/v2.0.1/client_tests/pas_client_response_bundle_validation_test.rb} +44 -20
  11. data/lib/davinci_pas_test_kit/custom_groups/v2.0.1/client_tests/pas_client_subscription_create_test.rb +49 -0
  12. data/lib/davinci_pas_test_kit/custom_groups/v2.0.1/client_tests/pas_client_subscription_pas_conformance_test.rb +48 -0
  13. data/lib/davinci_pas_test_kit/custom_groups/v2.0.1/pas_client_approval_group.rb +21 -9
  14. data/lib/davinci_pas_test_kit/custom_groups/v2.0.1/pas_client_authentication_group.rb +2 -2
  15. data/lib/davinci_pas_test_kit/custom_groups/v2.0.1/pas_client_denial_group.rb +21 -22
  16. data/lib/davinci_pas_test_kit/custom_groups/v2.0.1/pas_client_pended_group.rb +97 -31
  17. data/lib/davinci_pas_test_kit/docs/client_suite_description_v201.md +213 -72
  18. data/lib/davinci_pas_test_kit/endpoints/claim_endpoint.rb +85 -134
  19. data/lib/davinci_pas_test_kit/endpoints/subscription_create_endpoint.rb +96 -0
  20. data/lib/davinci_pas_test_kit/endpoints/subscription_status_endpoint.rb +90 -0
  21. data/lib/davinci_pas_test_kit/generated/v2.0.1/pas_inquiry_request_bundle/metadata.yml +0 -2
  22. data/lib/davinci_pas_test_kit/generated/v2.0.1/pas_inquiry_request_bundle/server_pas_inquiry_request_bundle_validation_test.rb +3 -1
  23. data/lib/davinci_pas_test_kit/generated/v2.0.1/pas_inquiry_response_bundle/server_pas_inquiry_response_bundle_validation_test.rb +2 -1
  24. data/lib/davinci_pas_test_kit/generated/v2.0.1/pas_request_bundle/metadata.yml +0 -2
  25. data/lib/davinci_pas_test_kit/generated/v2.0.1/pas_request_bundle/server_pas_request_bundle_validation_test.rb +3 -1
  26. data/lib/davinci_pas_test_kit/generated/v2.0.1/pas_response_bundle/metadata.yml +0 -4
  27. data/lib/davinci_pas_test_kit/generated/v2.0.1/pas_response_bundle/server_pas_response_bundle_validation_test.rb +2 -1
  28. data/lib/davinci_pas_test_kit/generated/v2.0.1/pas_server_denial_use_case_group.rb +1 -1
  29. data/lib/davinci_pas_test_kit/generated/v2.0.1/pas_server_pended_use_case_group.rb +6 -5
  30. data/lib/davinci_pas_test_kit/generated/v2.0.1/server_suite.rb +1 -0
  31. data/lib/davinci_pas_test_kit/generator/group_generator.rb +9 -8
  32. data/lib/davinci_pas_test_kit/generator/group_metadata_extractor.rb +7 -3
  33. data/lib/davinci_pas_test_kit/generator/templates/suite.rb.erb +1 -0
  34. data/lib/davinci_pas_test_kit/generator/validation_test_generator.rb +19 -56
  35. data/lib/davinci_pas_test_kit/generator/value_extractor.rb +4 -1
  36. data/lib/davinci_pas_test_kit/generator.rb +1 -1
  37. data/lib/davinci_pas_test_kit/jobs/send_pas_subscription_notification.rb +136 -0
  38. data/lib/davinci_pas_test_kit/jobs/send_subscription_handshake.rb +139 -0
  39. data/lib/davinci_pas_test_kit/pas_bundle_validation.rb +8 -7
  40. data/lib/davinci_pas_test_kit/response_generator.rb +397 -0
  41. data/lib/davinci_pas_test_kit/tags.rb +9 -0
  42. data/lib/davinci_pas_test_kit/urls.rb +8 -0
  43. data/lib/davinci_pas_test_kit/user_input_response.rb +11 -8
  44. data/lib/davinci_pas_test_kit/validation_test.rb +0 -1
  45. data/lib/davinci_pas_test_kit/version.rb +2 -2
  46. metadata +30 -14
  47. data/lib/davinci_pas_test_kit/custom_groups/v2.0.1/client_tests/pas_client_denial_submit_response_attest.rb +0 -38
  48. data/lib/davinci_pas_test_kit/custom_groups/v2.0.1/client_tests/pas_client_pended_inquire_response_attest.rb +0 -39
  49. data/lib/davinci_pas_test_kit/custom_groups/v2.0.1/client_tests/pas_client_pended_inquire_test.rb +0 -35
  50. data/lib/davinci_pas_test_kit/custom_groups/v2.0.1/client_tests/pas_client_pended_submit_response_attest.rb +0 -39
  51. data/lib/davinci_pas_test_kit/generator/templates/validation_client.rb.erb +0 -50
@@ -1,37 +1,43 @@
1
1
  require_relative '../../../pas_bundle_validation'
2
2
  require_relative '../../../user_input_response'
3
+ require_relative '../../../response_generator'
3
4
 
4
5
  module DaVinciPASTestKit
5
6
  module DaVinciPASV201
6
- class ClientPendedPasResponseBundleValidationTest < Inferno::Test
7
+ class PasClientResponseBundleValidationTest < Inferno::Test
7
8
  include DaVinciPASTestKit::PasBundleValidation
8
9
  include UserInputResponse
10
+ include ResponseGenerator
9
11
 
10
- id :pas_client_v201_pended_pas_response_bundle_validation_test
11
- title '[USER INPUT VALIDATION] Response Bundle is valid'
12
+ id :pas_client_v201_response_bundle_validation_test
13
+ title '[USER INPUT VERIFICATION] Submit Response Bundle is valid'
12
14
  description %(
13
- **USER INPUT VALIDATION**: This test validates input provided by the user instead of the system under test.
15
+ **USER INPUT VERIFICATION**: This test verifies input provided by the tester instead of the system under test.
14
16
  Errors encountered will be treated as a skip instead of a failure.
15
-
16
- This test validates the conformity of the
17
- user input to the
18
- [PAS Response Bundle](http://hl7.org/fhir/us/davinci-pas/StructureDefinition/profile-pas-response-bundle) structure.
19
- It also checks that other conformance requirements defined in the [PAS Formal
17
+
18
+ This test verifies the conformity of the submit response sent by Inferno, which will have been
19
+ either:
20
+ - the response body provided by the tester in the corresponding input, or
21
+ - created by Inferno from the $submit Bundle.
22
+
23
+ In either case, this test verifies the conformity of the response body to the
24
+ [PAS Response Bundle](https://hl7.org/fhir/us/davinci-pas/STU2/StructureDefinition-profile-pas-response-bundle.html)
25
+ structure. It also checks that other conformance requirements defined in the [PAS Formal
20
26
  Specification](https://hl7.org/fhir/us/davinci-pas/STU2/specification.html),
21
27
  such as the presence of all referenced instances within the bundle and the
22
28
  conformance of those instances to the appropriate profiles, are met.
23
-
29
+
24
30
  It verifies the presence of mandatory elements and that elements with
25
31
  required bindings contain appropriate values. CodeableConcept element
26
32
  bindings will fail if none of their codings have a code/system belonging
27
33
  to the bound ValueSet. Quantity, Coding, and code element bindings will
28
34
  fail if their code/system are not found in the valueset.
29
-
35
+
30
36
  Note that because X12 value sets are not public, elements bound to value
31
37
  sets containing X12 codes are not validated.
32
-
38
+
33
39
  **Limitations**
34
-
40
+
35
41
  Due to recognized errors in the PAS IG around extension context definitions,
36
42
  this test may not pass due to spurious errors of the form "The extension
37
43
  [extension url] is not allowed at this point". See [this
@@ -39,24 +45,42 @@ module DaVinciPASTestKit
39
45
  for additional details.
40
46
  )
41
47
 
42
- def resource_type
43
- 'Bundle'
44
- end
45
-
46
48
  def request_type
47
49
  'submit'
48
50
  end
49
51
 
52
+ def workflow_tag
53
+ config.options[:workflow_tag]
54
+ end
55
+
56
+ def target_user_input
57
+ case workflow_tag
58
+ when APPROVAL_WORKFLOW_TAG
59
+ :approval_json_response
60
+ when DENIAL_WORKFLOW_TAG
61
+ :denial_json_response
62
+ when PENDED_WORKFLOW_TAG
63
+ :pended_json_response
64
+ end
65
+ end
66
+
50
67
  run do
51
- check_user_inputted_response :pended_json_response
68
+ load_tagged_requests(workflow_tag, SUBMIT_TAG)
69
+ skip_if requests.empty?, 'No responses to verify because no submit requests were made.'
70
+ message = if user_inputted_response? target_user_input
71
+ "Invalid response generated from provided input '#{input_title(target_user_input)}':"
72
+ else
73
+ 'Invalid response generated from the submitted claim:'
74
+ end
75
+
52
76
  validate_pas_bundle_json(
53
- pended_json_response,
77
+ request.response_body,
54
78
  'http://hl7.org/fhir/us/davinci-pas/StructureDefinition/profile-pas-response-bundle',
55
79
  '2.0.1',
56
80
  request_type,
57
81
  'response_bundle',
58
82
  skips: true,
59
- message: "Invalid input for '#{input_title(:pended_json_response)}':"
83
+ message:
60
84
  )
61
85
  end
62
86
  end
@@ -0,0 +1,49 @@
1
+ require_relative '../../../urls'
2
+
3
+ module DaVinciPASTestKit
4
+ module DaVinciPASV201
5
+ class PASClientSubscriptionCreateTest < Inferno::Test
6
+ include URLs
7
+
8
+ id :pas_client_v201_subscription_create_test
9
+ title 'Client submits a Subscription Creation Request'
10
+ description %(
11
+ Inferno will wait for a Subscription Creation request
12
+ and then perform a handshake to activate the Subscription.
13
+ )
14
+ input :access_token,
15
+ title: 'Access Token',
16
+ description: %(
17
+ Access token that the client will provide in the Authorization header of each request
18
+ made during this test.
19
+ )
20
+ input :client_endpoint_access_token,
21
+ optional: true,
22
+ title: 'Client Notification Access Token',
23
+ description: %(
24
+ The bearer token that Inferno will send on requests to the client under test's rest-hook notification
25
+ endpoint. Not needed if the client under test will create a Subscription with an appropriate header value
26
+ in the `channel.header` element. If a value for the `authorization` header is provided in
27
+ `channel.header`, this value will override it.
28
+ )
29
+
30
+ run do
31
+ wait(
32
+ identifier: access_token,
33
+ message: %(
34
+ **Subscription Creation Test**:
35
+
36
+ Submit a POST with a Subscription to:
37
+
38
+ `#{fhir_subscription_url}`
39
+
40
+ The request must have an `Authorization` header with the value `Bearer #{access_token}`.
41
+
42
+ Upon receipt, Inferno will send a handshake request to verify that notifications can be
43
+ delivered and continue the test with a pass or fail based on the result.
44
+ )
45
+ )
46
+ end
47
+ end
48
+ end
49
+ end
@@ -0,0 +1,48 @@
1
+ # frozen_string_literal: true
2
+
3
+ module DaVinciPASTestKit
4
+ module DaVinciPASV201
5
+ class SubscriptionPASConformanceTest < Inferno::Test
6
+ id :pas_client_v201_subscription_pas_conformance_test
7
+ title 'Client Subscription PAS Conformance Verification'
8
+ description %(
9
+ This test verifies that the Subscription created by the client under test
10
+ is conformant to PAS requirements on the Subscription, including
11
+ - The use of the [PAS-defined Subscription
12
+ Topic](https://hl7.org/fhir/us/davinci-pas/STU2/SubscriptionTopic-PASSubscriptionTopic.html), and
13
+ - Inclusion of filter criteria for the client's organization.
14
+ )
15
+
16
+ run do
17
+ load_tagged_requests(SUBSCRIPTION_CREATE_TAG)
18
+ skip_if(requests.none?, 'Inferno did not receive a Subscription creation request')
19
+ subscription_resource = request.request_body
20
+
21
+ assert_valid_json(subscription_resource)
22
+ subscription = JSON.parse(subscription_resource)
23
+
24
+ unless subscription['criteria'] == 'http://hl7.org/fhir/us/davinci-pas/SubscriptionTopic/PASSubscriptionTopic'
25
+ add_message('error', %(
26
+ The created Subscription must use the PAS-defined Subscription topic
27
+ `http://hl7.org/fhir/us/davinci-pas/SubscriptionTopic/PASSubscriptionTopic`
28
+ in the `Subscription.criteria` element.
29
+ ))
30
+ end
31
+
32
+ filter_criteria = subscription.dig('_criteria', 'extension')
33
+ &.select do |ext|
34
+ ext['url'] == 'http://hl7.org/fhir/uv/subscriptions-backport/StructureDefinition/backport-filter-criteria'
35
+ end
36
+ unless filter_criteria&.length == 1
37
+ add_message('error', %(
38
+ The created Subscription must include a single filter on the submitting organization
39
+ in the `Subscription.criteria.extension` element.
40
+ ))
41
+ end
42
+
43
+ assert messages.none? { |msg| msg[:type] == 'error' },
44
+ 'The Created Subscription does not conform to PAS requirements - see messages for details.'
45
+ end
46
+ end
47
+ end
48
+ end
@@ -1,6 +1,8 @@
1
1
  require_relative 'client_tests/pas_client_approval_submit_test'
2
- require_relative 'client_tests/pas_client_approval_submit_response_attest'
3
- require_relative '../../generated/v2.0.1/client_tests/client_pas_request_bundle_validation_test'
2
+ require_relative 'client_tests/pas_client_response_attest'
3
+ require_relative 'client_tests/pas_client_request_bundle_validation_test'
4
+ require_relative 'client_tests/pas_client_response_bundle_validation_test'
5
+ require_relative '../../tags'
4
6
 
5
7
  module DaVinciPASTestKit
6
8
  module DaVinciPASV201
@@ -13,14 +15,24 @@ module DaVinciPASTestKit
13
15
  )
14
16
  run_as_group
15
17
 
16
- test from: :pas_client_v201_approval_submit_test,
17
- receives_request: :approval_claim
18
+ input :approval_json_response, optional: true
18
19
 
19
- test from: :pas_client_v201_pas_request_bundle_validation_test,
20
- uses_request: :approval_claim
21
-
22
- test from: :pas_client_v201_approval_submit_response_attest,
23
- uses_request: :approval_claim
20
+ test from: :pas_client_v201_approval_submit_test
21
+ test from: :pas_client_v201_request_bundle_validation_test,
22
+ config: { options: { workflow_tag: APPROVAL_WORKFLOW_TAG } }
23
+ test from: :pas_client_v201_response_bundle_validation_test,
24
+ config: { options: { workflow_tag: APPROVAL_WORKFLOW_TAG } }
25
+ test from: :pas_client_v201_response_attest,
26
+ title: 'Check that the client registers the request as approved (Attestation)',
27
+ description: %(
28
+ This test provides the tester an opportunity to observe their client following
29
+ the receipt of the approved response and attest that users are able to determine
30
+ that the response has been approved.
31
+ ),
32
+ config: { options: {
33
+ workflow_tag: APPROVAL_WORKFLOW_TAG,
34
+ attest_message: "I attest that the client system displays the submitted claim as 'approved' meaning that the user can proceed with ordering or providing the requested service." # rubocop:disable Layout/LineLength
35
+ } }
24
36
  end
25
37
  end
26
38
  end
@@ -23,7 +23,7 @@ module DaVinciPASTestKit
23
23
 
24
24
  Finally, make a valid token request that includes the specified `client_id`
25
25
  to indicated token endpoint. This should be a POST of an `x-www-form-encoded`
26
- body containing keys for `grant_type` with a value of `client_crendials` and
26
+ body containing keys for `grant_type` with a value of `client_credentials` and
27
27
  `client_id` with a value of the configured `client_id` value. For example, if
28
28
  the `client_id` value was `123`, then the body of the request would be:
29
29
 
@@ -38,7 +38,7 @@ module DaVinciPASTestKit
38
38
  the "Authorization" HTTP header with prefix "Bearer: ". In this example, the
39
39
  Authorization HTTP header would have value:
40
40
 
41
- ```Bearer: 97e792038d922bc3cf388b608e45c318```
41
+ ```Bearer 97e792038d922bc3cf388b608e45c318```
42
42
  )
43
43
  run_as_group
44
44
 
@@ -1,8 +1,9 @@
1
1
  require_relative 'client_tests/pas_client_denial_submit_test'
2
- require_relative 'client_tests/pas_client_denial_submit_response_attest'
3
- require_relative '../../generated/v2.0.1/client_tests/client_denial_pas_response_bundle_validation_test'
4
- require_relative '../../generated/v2.0.1/client_tests/client_pas_request_bundle_validation_test'
2
+ require_relative 'client_tests/pas_client_response_attest'
3
+ require_relative 'client_tests/pas_client_response_bundle_validation_test'
4
+ require_relative 'client_tests/pas_client_request_bundle_validation_test'
5
5
  require_relative '../../user_input_response'
6
+ require_relative '../../tags'
6
7
 
7
8
  module DaVinciPASTestKit
8
9
  module DaVinciPASV201
@@ -16,26 +17,24 @@ module DaVinciPASTestKit
16
17
  )
17
18
  run_as_group
18
19
 
19
- input :denial_json_response,
20
- title: 'Claim denied response JSON',
21
- type: 'textarea',
22
- optional: true,
23
- description: %(
24
- The response provided will be validated against the PAS Response Bundle profile. If determined to be
25
- invalid, a validation message will be returned, and the test group will be skipped.
26
- )
20
+ input :denial_json_response, optional: true
27
21
 
28
- test from: :pas_client_v201_denial_submit_test,
29
- receives_request: :denial_claim,
30
- respond_with: :denial_json_response
31
-
32
- test from: :pas_client_v201_denial_pas_response_bundle_validation_test
33
-
34
- test from: :pas_client_v201_pas_request_bundle_validation_test,
35
- uses_request: :denial_claim
36
-
37
- test from: :pas_client_v201_denial_submit_response_attest,
38
- uses_request: :denial_claim
22
+ test from: :pas_client_v201_denial_submit_test
23
+ test from: :pas_client_v201_request_bundle_validation_test,
24
+ config: { options: { workflow_tag: DENIAL_WORKFLOW_TAG } }
25
+ test from: :pas_client_v201_response_bundle_validation_test,
26
+ config: { options: { workflow_tag: DENIAL_WORKFLOW_TAG } }
27
+ test from: :pas_client_v201_response_attest,
28
+ title: 'Check that the client registers the request as denied (Attestation)',
29
+ description: %(
30
+ This test provides the tester an opportunity to observe their client following
31
+ the receipt of the denied response and attest that users are able to determine
32
+ that the response has been denied.
33
+ ),
34
+ config: { options: {
35
+ workflow_tag: DENIAL_WORKFLOW_TAG,
36
+ attest_message: "I attest that the client system displays the submitted claim as 'denied'."
37
+ } }
39
38
  end
40
39
  end
41
40
  end
@@ -1,11 +1,11 @@
1
1
  require_relative 'client_tests/pas_client_pended_submit_test'
2
- require_relative 'client_tests/pas_client_pended_submit_response_attest'
3
- require_relative 'client_tests/pas_client_pended_inquire_test'
4
- require_relative 'client_tests/pas_client_pended_inquire_response_attest'
5
- require_relative '../../generated/v2.0.1/client_tests/client_pended_pas_response_bundle_validation_test'
6
- require_relative '../../generated/v2.0.1/client_tests/client_pas_request_bundle_validation_test'
7
- require_relative '../../generated/v2.0.1/client_tests/client_pended_pas_inquiry_request_bundle_validation_test'
2
+ require_relative 'client_tests/pas_client_response_attest'
3
+ require_relative 'client_tests/pas_client_response_bundle_validation_test'
4
+ require_relative 'client_tests/pas_client_inquire_response_bundle_validation_test'
5
+ require_relative 'client_tests/pas_client_request_bundle_validation_test'
6
+ require_relative 'client_tests/pas_client_inquire_request_bundle_validation_test'
8
7
  require_relative '../../user_input_response'
8
+ require_relative '../../tags'
9
9
 
10
10
  module DaVinciPASTestKit
11
11
  module DaVinciPASV201
@@ -16,41 +16,107 @@ module DaVinciPASTestKit
16
16
  description %(
17
17
  Demonstrate the ability of the client to initiate a prior authorization
18
18
  request and respond appropriately to a 'pended' decision, including
19
- waiting for a notification that an update has been made (not currently
20
- implemented) and making an inquiry request to retrieve the final result.
19
+ waiting for a notification that an update has been made
20
+ and making an inquiry request to retrieve the final result.
21
21
  )
22
22
  run_as_group
23
23
 
24
- input :pended_json_response,
25
- title: 'Claim pended response JSON',
26
- type: 'textarea',
27
- optional: true,
28
- description: %(
29
- The response provided will be validated against the PAS Response Bundle profile. If determined to be
30
- invalid, a validation message will be returned, and the test group will be skipped.
31
- )
24
+ input :pended_json_response, optional: true
25
+ input :inquire_json_response, optional: true
32
26
 
33
- test from: :pas_client_v201_pended_submit_test,
34
- receives_request: :pended_claim,
35
- respond_with: :pended_json_response
27
+ group do
28
+ title 'Perform the pended workflow'
29
+ description %(
30
+ All interactions for the pended prior authorization request workflow
31
+ between Inferno and the client under test will be performed during this test
32
+ including
33
+ - A `$submit` request from the client to Inferno where Inferno returns a pended response.
34
+ - A notification that the prior authorization decision has been finalized from Inferno
35
+ to the client under test.
36
+ - An `$inquire` request from the client to Inferno where Inferno returns an approved response.
37
+ )
36
38
 
37
- test from: :pas_client_v201_pended_pas_response_bundle_validation_test
39
+ test from: :pas_client_v201_pended_submit_test
40
+ end
38
41
 
39
- test from: :pas_client_v201_pas_request_bundle_validation_test,
40
- uses_request: :pended_claim
42
+ group do
43
+ title 'Verify $submit interaction'
41
44
 
42
- test from: :pas_client_v201_pended_submit_response_attest,
43
- uses_request: :pended_claim
45
+ test from: :pas_client_v201_request_bundle_validation_test,
46
+ config: { options: { workflow_tag: PENDED_WORKFLOW_TAG } }
47
+ test from: :pas_client_v201_response_bundle_validation_test,
48
+ config: { options: { workflow_tag: PENDED_WORKFLOW_TAG } }
49
+ test from: :pas_client_v201_response_attest,
50
+ title: 'Check that the client registers the request as pended (Attestation)',
51
+ description: %(
52
+ This test provides the tester an opportunity to observe their client following
53
+ the receipt of the pended response and attest that users are able to determine
54
+ that the response has been pended and a decision will be forthcoming.
55
+ ),
56
+ config: { options: {
57
+ workflow_tag: PENDED_WORKFLOW_TAG,
58
+ attest_message: "I attest that following the receipt of the 'pended' response to the submitted claim, the client system indicates to users that a final decision on request has not yet been made." # rubocop:disable Layout/LineLength
59
+ } }
60
+ end
44
61
 
45
- test from: :pas_client_v201_pended_inquire_test,
46
- uses_request: :pended_claim,
47
- receives_request: :pended_inquiry
62
+ group do
63
+ title 'Verify notification interaction'
48
64
 
49
- test from: :pas_client_v201_pended_pas_inquiry_request_bundle_validation_test,
50
- uses_request: :pended_inquiry
65
+ test from: :subscriptions_r4_client_notification_input_verification,
66
+ title: '[USER INPUT VERIFICATION] Tester-provided event notification Bundle is conformant',
67
+ description: %(
68
+ This test checks that the notification Bundle sent to the client, which will be either
69
+ the tester-provided notification Bundle in the **Claim updated notification JSON** input
70
+ or mocked by Inferno based on details in the Subscription and submitted Claim, is conformant
71
+ to Subscription Backport IG requirements.
72
+ ),
73
+ config: {
74
+ inputs: {
75
+ notification_bundle: { optional: true } # doesn't use the input (bug in Subscriptions)
76
+ }
77
+ }
78
+ test from: :subscriptions_r4_client_notification_input_payload_verification,
79
+ title: '[USER INPUT VERIFICATION] Tester-provided event notification Bundle matches the Subscription',
80
+ description: %(
81
+ This test checks that the notification Bundle sent to the client, which will be either
82
+ the tester-provided notification Bundle in the **Claim updated notification JSON** input
83
+ or mocked by Inferno based on details in the Subscription and submitted Claim, matches the details
84
+ requested in the Subscription provided during the **2.1** "PAS Subscription Setup" tests.
85
+ ),
86
+ config: {
87
+ inputs: {
88
+ notification_bundle: { optional: true } # doesn't use the input (bug in Subscriptions)
89
+ }
90
+ }
91
+ # test for PAS-specific requirements? Current decision: no, there isn't anything hard in the spec
92
+ # and testers have to demonstrate and attest that their systems work, which will require some
93
+ # correspondence.
94
+ test from: :subscriptions_r4_client_event_notification_verification,
95
+ title: 'Client accepts the "claim updated" event notification',
96
+ description: %(
97
+ This test checks that the client responds appropriately to the event notification request.
98
+ )
99
+ end
51
100
 
52
- test from: :pas_client_v201_pended_inquire_response_attest,
53
- uses_request: :pended_inquiry
101
+ group do
102
+ title 'Verify $inquire interaction'
103
+
104
+ test from: :pas_client_v201_inquire_request_bundle_validation_test,
105
+ config: { options: { workflow_tag: PENDED_WORKFLOW_TAG } }
106
+ test from: :pas_client_v201_inquire_response_bundle_validation_test,
107
+ config: { options: { workflow_tag: PENDED_WORKFLOW_TAG } }
108
+ test from: :pas_client_v201_response_attest,
109
+ title: 'Check that the client registers the request as approved (Attestation)',
110
+ description: %(
111
+ This test provides the tester an opportunity to observe their client following
112
+ the receipt of the inquiry response with a final decision and attest that users
113
+ are able to determine that the response has been approved in full.
114
+ ),
115
+ config: { options: {
116
+ workflow_tag: PENDED_WORKFLOW_TAG,
117
+ attest_message: "I attest that the client system displays the submitted claim as 'approved' meaning that the user can proceed with ordering or providing the requested service." # rubocop:disable Layout/LineLength
118
+ } }
119
+ end
54
120
  end
55
121
  end
56
122
  end