ipa_test_kit 0.3.4 → 0.4.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 391ea153420e7803d26fa46ea9d4131166bca66f0fdb09ae501292319181af0f
4
- data.tar.gz: b7e419a3b96aeb74a46f25cf5e6cd0377c3180b0604241d48052465941018333
3
+ metadata.gz: 4562e71dcd89296da4487bd36d7345e269b0f6a8daf5c6a267cfb94015a1d3ad
4
+ data.tar.gz: 8e882d0a00df7b037fe66ae048c172a5e187649cab2c61ac5504e215a274e5bf
5
5
  SHA512:
6
- metadata.gz: 4cb887e5530f4ce134a47d34cf174d3a7d1334f0d46ebee7347ab7a635decab048cec5841856bba6f2a0ab571d8f1c1878ec89997dab51c8a347ac08b5ecb2e5
7
- data.tar.gz: 6173564545fa327b4fe5627c049580ac5b5fb1086f0c74e6f93d9bd3af2229b218168a5ff25b2c304298343c94537df6a50ab214a3464b692e1401053ab2dd5b
6
+ metadata.gz: 109a40b99ee9a6b37a465aff34c6dd2877ef150413cff323e31ff8f0478a0d47f9199387e3a31455d7369fa80ffbc5cde7437b9bba7de5697cd43105e900646a
7
+ data.tar.gz: 81490d60b155e4aa6bd3ace45ef93e94c11c6e086d40ae207618b1a3a8f9b9e1d867743444643b2f660fdb3d750db5c139ee50bb278293c48e6883b909969478
@@ -46,11 +46,13 @@ module IpaTestKit
46
46
  search.
47
47
  )
48
48
  version VERSION
49
+ id :ipa_v100
49
50
 
50
51
  VALIDATION_MESSAGE_FILTERS = [
51
52
  %r{Sub-extension url 'introspect' is not defined by the Extension http://fhir-registry\.smarthealthit\.org/StructureDefinition/oauth-uris},
52
53
  %r{Sub-extension url 'revoke' is not defined by the Extension http://fhir-registry\.smarthealthit\.org/StructureDefinition/oauth-uris},
53
54
  /Observation\.effective\.ofType\(Period\): .*vs-1:/, # Invalid invariant in FHIR v4.0.1
55
+ /\A\S+: \S+: URL value '.*' does not resolve/,
54
56
  ].freeze
55
57
 
56
58
  def self.metadata
@@ -59,8 +61,9 @@ module IpaTestKit
59
61
  end
60
62
  end
61
63
 
62
- validator do
63
- url ENV.fetch('IPA_V100_VALIDATOR_URL', 'http://validator_service:4567')
64
+ fhir_resource_validator do
65
+ igs 'hl7.fhir.uv.ipa#1.0.0'
66
+
64
67
  exclude_message do |message|
65
68
  VALIDATION_MESSAGE_FILTERS.any? { |filter| filter.match? message.message }
66
69
  end
@@ -70,9 +73,6 @@ module IpaTestKit
70
73
  end
71
74
  end
72
75
 
73
- id :ipa_v100
74
-
75
-
76
76
  input :url,
77
77
  title: 'FHIR Endpoint',
78
78
  description: 'URL of the FHIR endpoint'
@@ -53,8 +53,9 @@ module IpaTestKit
53
53
  "IPA #{ig_metadata.ig_version}"
54
54
  end
55
55
 
56
- def validator_env_name
57
- "IPA_#{ig_metadata.reformatted_version.upcase}_VALIDATOR_URL"
56
+ def ig_identifier
57
+ version = ig_metadata.ig_version[1..] # Remove leading 'v'
58
+ "hl7.fhir.uv.ipa##{version}"
58
59
  end
59
60
 
60
61
  def ig_link
@@ -165,8 +165,8 @@ module IpaTestKit
165
165
  # Only need to know if the resource is valid.
166
166
  # Calling resource_is_valid? causes validation errors to be logged.
167
167
  validator = find_validator(:default)
168
-
169
- outcome = FHIR::OperationOutcome.new(JSON.parse(validator.validate(resource, target_profile)))
168
+ validator_response = validator.validate(resource, target_profile)
169
+ outcome = validator.operation_outcome_from_hl7_wrapped_response(validator_response)
170
170
 
171
171
  message_hashes = outcome.issue&.map { |issue| validator.message_hash_from_issue(issue, resource) } || []
172
172
 
@@ -1,3 +1,3 @@
1
1
  module IpaTestKit
2
- VERSION = '0.3.4'
2
+ VERSION = '0.4.0'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ipa_test_kit
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.4
4
+ version: 0.4.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Inferno Core Team
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-12-11 00:00:00.000000000 Z
11
+ date: 2024-06-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: inferno_core
@@ -16,14 +16,14 @@ dependencies:
16
16
  requirements:
17
17
  - - ">="
18
18
  - !ruby/object:Gem::Version
19
- version: 0.4.2
19
+ version: 0.4.37
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - ">="
25
25
  - !ruby/object:Gem::Version
26
- version: 0.4.2
26
+ version: 0.4.37
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: smart_app_launch_test_kit
29
29
  requirement: !ruby/object:Gem::Requirement
@@ -306,12 +306,12 @@ files:
306
306
  - lib/ipa_test_kit/search_test_properties.rb
307
307
  - lib/ipa_test_kit/validation_test.rb
308
308
  - lib/ipa_test_kit/version.rb
309
- homepage: https://github.com/inferno_framework/ipa-test-kit
309
+ homepage: https://github.com/inferno-framework/ipa-test-kit
310
310
  licenses:
311
311
  - Apache-2.0
312
312
  metadata:
313
- homepage_uri: https://github.com/inferno_framework/ipa-test-kit
314
- source_code_uri: https://github.com/inferno_framework/ipa-test-kit
313
+ homepage_uri: https://github.com/inferno-framework/ipa-test-kit
314
+ source_code_uri: https://github.com/inferno-framework/ipa-test-kit
315
315
  post_install_message:
316
316
  rdoc_options: []
317
317
  require_paths: