trailblazer-core-utils 0.0.10 → 0.0.11
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/CHANGELOG.md +4 -0
- data/Gemfile +6 -6
- data/lib/trailblazer/core/utils/assert_run.rb +4 -8
- data/lib/trailblazer/core/utils/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: b590ee0dd14014d2c0b2b90308157b4937471c33d1502d6bbc9edaf16dbc0b9b
|
|
4
|
+
data.tar.gz: f8d5c37e05959a8b976de2f3b1cf69f6c997316d9592eae2ee5fd4e1a5658df1
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: d194bc36bc815aadf002e6881011b0b8a1e1fe7b064b6abba5398a356e8eb6b089f898a027d99edffc5b391e96a1796b6dba27558b8bb3e1c856c3455a247ac8
|
|
7
|
+
data.tar.gz: b636f63a10e2f3b674a6eb47b5fe70f0f79e0852888005dbdbe4c9110d6e7469988bc9423105f54a39c6d67bf39279948a086b854da4139c3e85699fbc323b21
|
data/CHANGELOG.md
CHANGED
data/Gemfile
CHANGED
|
@@ -7,10 +7,10 @@ gem "rake", "~> 13.0"
|
|
|
7
7
|
|
|
8
8
|
gem "minitest", "~> 5.0"
|
|
9
9
|
gem "minitest-line"
|
|
10
|
-
gem "trailblazer-activity", path: "../trailblazer-activity"
|
|
11
|
-
gem "trailblazer-circuit", path: "../trailblazer-circuit"
|
|
12
|
-
gem "trailblazer-activity-dsl", path: "../trailblazer-activity-dsl-linear"
|
|
10
|
+
# gem "trailblazer-activity", path: "../trailblazer-activity"
|
|
11
|
+
# gem "trailblazer-circuit", path: "../trailblazer-circuit"
|
|
12
|
+
# gem "trailblazer-activity-dsl", path: "../trailblazer-activity-dsl-linear"
|
|
13
13
|
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
14
|
+
gem "trailblazer-circuit", github: "trailblazer/trailblazer-circuit", branch: "3-0-dev"
|
|
15
|
+
gem "trailblazer-activity", github: "trailblazer/trailblazer-activity"#, branch: "3-0-dev"
|
|
16
|
+
gem "trailblazer-activity-dsl", github: "trailblazer/trailblazer-activity-dsl", branch: "3-0-dev"
|
|
@@ -1,21 +1,17 @@
|
|
|
1
1
|
module Trailblazer
|
|
2
2
|
module Core::Utils
|
|
3
3
|
module AssertRun
|
|
4
|
-
|
|
5
|
-
def assert_run(circuit = nil,
|
|
4
|
+
# TODO: Use .Builder() and never build a node here.
|
|
5
|
+
def assert_run(circuit = nil, id = nil, node: nil, terminus: nil, seq: nil,
|
|
6
|
+
flow_options: Circuit::Node::Runner.new(), signal: nil, target_ctx: {seq: []}, expected_target_variables: {}, **lib_ctx)
|
|
6
7
|
# If circuit isn't a Node instance already, wrap it in a "canonical node".
|
|
7
8
|
canonical_node = node ? node : Trailblazer::Circuit::Node[circuit, Trailblazer::Circuit::Processor] # TODO: remove :node and figure it out automatically.
|
|
8
9
|
|
|
9
|
-
# circuit_options = {runner: runner}.merge(circuit_options)
|
|
10
|
-
runner = circuit_options.fetch(:runner)
|
|
11
|
-
circuit_options = circuit_options.merge(node: canonical_node)
|
|
12
|
-
circuit_options = circuit_options.merge(context_implementation: Trailblazer::Circuit::Context) # FIXME: remove
|
|
13
|
-
|
|
14
10
|
lib_ctx = lib_ctx.merge(target_ctx: target_ctx)
|
|
15
11
|
|
|
16
12
|
# TODO: use the public Invoke.call API! will save us some lines of code above.
|
|
17
13
|
# lib_ctx, flow_options, signal = Activity::Invoke.invoke_runner(lib_ctx, flow_options, signal, **circuit_options)
|
|
18
|
-
lib_ctx, flow_options, signal =
|
|
14
|
+
lib_ctx, flow_options, signal = flow_options.(lib_ctx, flow_options, signal, canonical_node, id)
|
|
19
15
|
|
|
20
16
|
if terminus.is_a?(Symbol)
|
|
21
17
|
terminus = circuit.to_h[:outputs].fetch(terminus).signal
|