inferno_core 1.4.2 → 1.4.3
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.
- checksums.yaml +4 -4
- data/lib/inferno/apps/cli/execute_script.rb +8 -4
- data/lib/inferno/apps/cli/requirements_coverage_checker.rb +1 -1
- data/lib/inferno/dsl/fhir_resource_navigation.rb +12 -2
- data/lib/inferno/dsl/fhir_resource_validation.rb +96 -0
- data/lib/inferno/dsl/must_support_assessment.rb +19 -8
- data/lib/inferno/dsl/must_support_metadata_extractor.rb +44 -1
- data/lib/inferno/dsl/profile_metadata.rb +113 -0
- data/lib/inferno/dsl/resume_test_route.rb +4 -1
- data/lib/inferno/dsl/suite_endpoint.rb +164 -6
- data/lib/inferno/dsl.rb +1 -0
- data/lib/inferno/entities/ig.rb +51 -8
- data/lib/inferno/public/bundle.js +34 -34
- data/lib/inferno/public/bundle.js.LICENSE.txt +0 -2
- data/lib/inferno/test_runner.rb +55 -40
- data/lib/inferno/version.rb +1 -1
- metadata +3 -2
data/lib/inferno/test_runner.rb
CHANGED
|
@@ -59,51 +59,66 @@ module Inferno
|
|
|
59
59
|
end
|
|
60
60
|
|
|
61
61
|
def run_test(test, scratch)
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
62
|
+
around_test(test) do
|
|
63
|
+
inputs = load_inputs(test)
|
|
64
|
+
input_json_string = inputs_as_json(test, inputs)
|
|
65
|
+
|
|
66
|
+
test_instance =
|
|
67
|
+
test.new(
|
|
68
|
+
inputs:,
|
|
69
|
+
test_session_id: test_session.id,
|
|
70
|
+
scratch:,
|
|
71
|
+
suite_options: test_session.suite_options_hash
|
|
72
|
+
)
|
|
73
|
+
|
|
74
|
+
result = evaluate_runnable_result(test, test_instance, inputs)
|
|
75
|
+
|
|
76
|
+
outputs = save_outputs(test_instance)
|
|
77
|
+
output_json_string = JSON.generate(outputs)
|
|
78
|
+
|
|
79
|
+
result_params = {
|
|
80
|
+
messages: test_instance.messages,
|
|
81
|
+
requests: test_instance.requests,
|
|
82
|
+
result:,
|
|
83
|
+
result_message: test_instance.result_message,
|
|
84
|
+
input_json: input_json_string,
|
|
85
|
+
output_json: output_json_string
|
|
86
|
+
}.merge(test.reference_hash)
|
|
87
|
+
|
|
88
|
+
test_result =
|
|
89
|
+
if result == 'wait'
|
|
90
|
+
# The waiting status and the wait result must become visible to
|
|
91
|
+
# readers atomically, so that pollers never see the run waiting
|
|
92
|
+
# without the waiting test's result being present.
|
|
93
|
+
Inferno::Application['db.connection'].transaction do
|
|
94
|
+
test_runs_repo.mark_as_waiting(test_run.id, test_instance.identifier, test_instance.wait_timeout)
|
|
95
|
+
persist_result(result_params)
|
|
96
|
+
end
|
|
97
|
+
else
|
|
94
98
|
persist_result(result_params)
|
|
95
99
|
end
|
|
96
|
-
else
|
|
97
|
-
persist_result(result_params)
|
|
98
|
-
end
|
|
99
100
|
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
101
|
+
# If running a single test, update its parents' results. If running a
|
|
102
|
+
# group or suite, #run_group handles updating the parents.
|
|
103
|
+
update_parent_result(test.parent) if test_run.test_id.present?
|
|
103
104
|
|
|
104
|
-
|
|
105
|
+
test_result
|
|
106
|
+
end
|
|
107
|
+
end
|
|
105
108
|
|
|
106
|
-
|
|
109
|
+
# Wraps the execution of a single test. Prepend a module overriding this method
|
|
110
|
+
# to run instrumentation around each test, for example to emit a distinct trace,
|
|
111
|
+
# span, or timing metric per test instead of one that spans the whole run.
|
|
112
|
+
#
|
|
113
|
+
# An override must call `super` exactly once and return its value unchanged:
|
|
114
|
+
# it is the test's result, and parent results are rolled up from it. An
|
|
115
|
+
# override that does not call `super` silently skips the test.
|
|
116
|
+
#
|
|
117
|
+
# @param test [Class] the test being run (an Inferno::Entities::Test subclass)
|
|
118
|
+
# @yield executes the test and returns its result
|
|
119
|
+
# @return the value returned by the block
|
|
120
|
+
def around_test(_test)
|
|
121
|
+
yield
|
|
107
122
|
end
|
|
108
123
|
|
|
109
124
|
def check_inputs(test, _test_instance, inputs)
|
data/lib/inferno/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: inferno_core
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.4.
|
|
4
|
+
version: 1.4.3
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Stephen MacVicar
|
|
@@ -10,7 +10,7 @@ authors:
|
|
|
10
10
|
autorequire:
|
|
11
11
|
bindir: bin
|
|
12
12
|
cert_chain: []
|
|
13
|
-
date: 2026-
|
|
13
|
+
date: 2026-08-26 00:00:00.000000000 Z
|
|
14
14
|
dependencies:
|
|
15
15
|
- !ruby/object:Gem::Dependency
|
|
16
16
|
name: activesupport
|
|
@@ -678,6 +678,7 @@ files:
|
|
|
678
678
|
- lib/inferno/dsl/must_support_metadata_extractor.rb
|
|
679
679
|
- lib/inferno/dsl/oauth_credentials.rb
|
|
680
680
|
- lib/inferno/dsl/primitive_type.rb
|
|
681
|
+
- lib/inferno/dsl/profile_metadata.rb
|
|
681
682
|
- lib/inferno/dsl/request_storage.rb
|
|
682
683
|
- lib/inferno/dsl/requirement_set.rb
|
|
683
684
|
- lib/inferno/dsl/result_collection.rb
|