trailblazer-operation 0.2.1 → 0.2.2
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/CHANGES.md +5 -0
- data/Gemfile +1 -1
- data/lib/trailblazer/operation.rb +4 -4
- data/lib/trailblazer/operation/version.rb +1 -1
- data/test/operation_test.rb +4 -4
- data/test/result_test.rb +1 -1
- data/test/trace_test.rb +8 -8
- data/trailblazer-operation.gemspec +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3374814d5a9e505e40d20d3598a3d67fd868a476659ab7a1c73685aa7a8cc375
|
4
|
+
data.tar.gz: 1e26729cfc2319be1644de1bdb38bcf35715f25adc355ecdb386d7abc5cb158f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3d4b658f8f3c97d2b011949fbc19b2e58ea8e2b5ce192dd280540a6040429b20536ddb400f29c0a6be19a7588ab360f928071d2bcef6c69d88c84a24a9470abe
|
7
|
+
data.tar.gz: 05fc186cec428608351635c2e33f196489e4a813913574019ad1f95a1d90d0b974a2e0b33154ed0feb9d785eee962e7fc8205f11c364bf423e058ce484894398
|
data/CHANGES.md
CHANGED
data/Gemfile
CHANGED
@@ -31,10 +31,10 @@ module Trailblazer
|
|
31
31
|
|
32
32
|
module FastTrackActivity
|
33
33
|
builder_options = {
|
34
|
-
track_end: Railway::End::Success.new(:success),
|
35
|
-
failure_end: Railway::End::Failure.new(:failure),
|
36
|
-
pass_fast_end: Railway::End::PassFast.new(:pass_fast),
|
37
|
-
fail_fast_end: Railway::End::FailFast.new(:fail_fast),
|
34
|
+
track_end: Railway::End::Success.new(semantic: :success),
|
35
|
+
failure_end: Railway::End::Failure.new(semantic: :failure),
|
36
|
+
pass_fast_end: Railway::End::PassFast.new(semantic: :pass_fast),
|
37
|
+
fail_fast_end: Railway::End::FailFast.new(semantic: :fail_fast),
|
38
38
|
}
|
39
39
|
|
40
40
|
extend Activity::FastTrack( pipeline: Railway::Normalizer::Pipeline, builder_options: builder_options )
|
data/test/operation_test.rb
CHANGED
@@ -81,10 +81,10 @@ class DeclarativeApiTest < Minitest::Spec
|
|
81
81
|
end
|
82
82
|
|
83
83
|
it "provides #outputs" do
|
84
|
-
Activity::Introspect.Outputs(Edit.outputs).must_equal %{success=> (#<
|
85
|
-
failure=> (#<
|
86
|
-
pass_fast=> (#<
|
87
|
-
fail_fast=> (#<
|
84
|
+
Activity::Introspect.Outputs(Edit.outputs).must_equal %{success=> (#<Trailblazer::Operation::Railway::End::Success semantic=:success>, success)
|
85
|
+
failure=> (#<Trailblazer::Operation::Railway::End::Failure semantic=:failure>, failure)
|
86
|
+
pass_fast=> (#<Trailblazer::Operation::Railway::End::PassFast semantic=:pass_fast>, pass_fast)
|
87
|
+
fail_fast=> (#<Trailblazer::Operation::Railway::End::FailFast semantic=:fail_fast>, fail_fast)}
|
88
88
|
end
|
89
89
|
|
90
90
|
it "is an Interface" do
|
data/test/result_test.rb
CHANGED
@@ -4,7 +4,7 @@ class RailwayResultTest < Minitest::Spec
|
|
4
4
|
Result = Trailblazer::Operation::Railway::Result
|
5
5
|
Success = Trailblazer::Operation::Railway::End::Success
|
6
6
|
|
7
|
-
let(:event) { Success.new(nil) }
|
7
|
+
let(:event) { Success.new(semantic: nil) }
|
8
8
|
let (:success) { Result.new(true, { "x"=> String }, event) }
|
9
9
|
|
10
10
|
it { success.success?.must_equal true }
|
data/test/trace_test.rb
CHANGED
@@ -35,29 +35,29 @@ class TraceTest < Minitest::Spec
|
|
35
35
|
|
36
36
|
puts output = Trailblazer::Activity::Trace::Present.tree(stack)
|
37
37
|
|
38
|
-
output.gsub(/0x\w+/, "").gsub(/@.+_test/, "").must_equal %{|-- #<
|
38
|
+
output.gsub(/0x\w+/, "").gsub(/@.+_test/, "").must_equal %{|-- #<Trailblazer::Activity::Start semantic=:default>
|
39
39
|
|-- Create.task.a
|
40
40
|
|-- MyNested
|
41
|
-
| |-- #<
|
41
|
+
| |-- #<Trailblazer::Activity::Start semantic=:default>
|
42
42
|
| |-- B.task.b
|
43
43
|
| |-- B.task.e
|
44
|
-
| `-- #<
|
44
|
+
| `-- #<Trailblazer::Operation::Railway::End::Success semantic=:success>
|
45
45
|
|-- Create.task.c
|
46
46
|
|-- Create.task.params
|
47
|
-
`-- #<
|
47
|
+
`-- #<Trailblazer::Operation::Railway::End::Failure semantic=:failure>}
|
48
48
|
end
|
49
49
|
|
50
50
|
it "Operation::trace" do
|
51
51
|
result = Create.trace({ params: { x: 1 }, a_return: true })
|
52
|
-
result.wtf.gsub(/0x\w+/, "").gsub(/@.+_test/, "").must_equal %{|-- #<
|
52
|
+
result.wtf.gsub(/0x\w+/, "").gsub(/@.+_test/, "").must_equal %{|-- #<Trailblazer::Activity::Start semantic=:default>
|
53
53
|
|-- Create.task.a
|
54
54
|
|-- MyNested
|
55
|
-
| |-- #<
|
55
|
+
| |-- #<Trailblazer::Activity::Start semantic=:default>
|
56
56
|
| |-- B.task.b
|
57
57
|
| |-- B.task.e
|
58
|
-
| `-- #<
|
58
|
+
| `-- #<Trailblazer::Operation::Railway::End::Success semantic=:success>
|
59
59
|
|-- Create.task.c
|
60
60
|
|-- Create.task.params
|
61
|
-
`-- #<
|
61
|
+
`-- #<Trailblazer::Operation::Railway::End::Success semantic=:success>}
|
62
62
|
end
|
63
63
|
end
|
@@ -17,7 +17,7 @@ Gem::Specification.new do |spec|
|
|
17
17
|
spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
|
18
18
|
spec.require_paths = ["lib"]
|
19
19
|
|
20
|
-
spec.add_dependency "trailblazer-activity", ">= 0.4.
|
20
|
+
spec.add_dependency "trailblazer-activity", ">= 0.4.2", "< 0.5.0"
|
21
21
|
spec.add_dependency "trailblazer-context", ">= 0.1.1", "< 0.3.0"
|
22
22
|
|
23
23
|
spec.add_development_dependency "bundler"
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: trailblazer-operation
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Nick Sutterer
|
@@ -16,7 +16,7 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - ">="
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: 0.4.
|
19
|
+
version: 0.4.2
|
20
20
|
- - "<"
|
21
21
|
- !ruby/object:Gem::Version
|
22
22
|
version: 0.5.0
|
@@ -26,7 +26,7 @@ dependencies:
|
|
26
26
|
requirements:
|
27
27
|
- - ">="
|
28
28
|
- !ruby/object:Gem::Version
|
29
|
-
version: 0.4.
|
29
|
+
version: 0.4.2
|
30
30
|
- - "<"
|
31
31
|
- !ruby/object:Gem::Version
|
32
32
|
version: 0.5.0
|