distribot-planner 0.1.3 → 0.1.4
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/Gemfile.lock +1 -1
- data/distribot-planner.gemspec +1 -1
- data/lib/distribot/plan.rb +3 -0
- data/spec/distribot-plan/plan_spec.rb +3 -3
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: a71e3447a3c86f9ea59cd86936be44a3769343b8
|
|
4
|
+
data.tar.gz: 4ef4b5ff120d92e0c2bc73c7d6b7ca4b05e7e979
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 44b86d76a2bde0d1492051b4927642e01e6ff0b55a977c2b987ed5974b659550e35a6368b61bf8f8aee465fedf2d9590fee749f01c19107483a012eb6d4f5a7b
|
|
7
|
+
data.tar.gz: fc35ae75218602bafa9472b79cb9ee9facfdd1c31a6ca1cb0970b9a0e723a43fb1796a62cc67683096203d125e61fa2acf26e83b54fac3b4db7a85431ec77374
|
data/Gemfile.lock
CHANGED
data/distribot-planner.gemspec
CHANGED
data/lib/distribot/plan.rb
CHANGED
|
@@ -32,6 +32,9 @@ module Distribot
|
|
|
32
32
|
name: 'phase %d/%d' % [ idx + 1, grouped.count ],
|
|
33
33
|
handlers: group.map(&:handler_data)
|
|
34
34
|
}
|
|
35
|
+
if grouped[idx + 1]
|
|
36
|
+
info[:transitions_to] = 'phase %d/%d' % [ idx + 2, grouped.count ]
|
|
37
|
+
end
|
|
35
38
|
info.merge!(is_initial: true) if idx == 0
|
|
36
39
|
info.merge!(is_final: true) if idx + 1 == grouped.count
|
|
37
40
|
info
|
|
@@ -107,9 +107,9 @@ describe Distribot::Plan do
|
|
|
107
107
|
end
|
|
108
108
|
end
|
|
109
109
|
@expected_schedule = [
|
|
110
|
-
{name: 'phase 1/4', is_initial: true, handlers: [{name: 'Step1Handler'}]},
|
|
111
|
-
{name: 'phase 2/4', handlers: [{name: 'Foo'},{name: 'Bar'},{name: 'Baz'}]},
|
|
112
|
-
{name: 'phase 3/4', handlers: [{name: 'Bux'},{name: 'Qux'}]},
|
|
110
|
+
{name: 'phase 1/4', is_initial: true, transitions_to: 'phase 2/4', handlers: [{name: 'Step1Handler'}]},
|
|
111
|
+
{name: 'phase 2/4', transitions_to: 'phase 3/4', handlers: [{name: 'Foo'},{name: 'Bar'},{name: 'Baz'}]},
|
|
112
|
+
{name: 'phase 3/4', transitions_to: 'phase 4/4', handlers: [{name: 'Bux'},{name: 'Qux'}]},
|
|
113
113
|
{name: 'phase 4/4', is_final: true, handlers: [{name: 'Flux'}]}
|
|
114
114
|
]
|
|
115
115
|
end
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: distribot-planner
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.1.
|
|
4
|
+
version: 0.1.4
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- John Drago
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2016-07-
|
|
11
|
+
date: 2016-07-03 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: bundler
|