henry-container 0.0.55 → 0.0.56
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.
- data/lib/henry/container.rb +12 -8
- data/lib/henry/container/version.rb +1 -1
- metadata +2 -2
data/lib/henry/container.rb
CHANGED
@@ -23,11 +23,13 @@ module Henry
|
|
23
23
|
self.before_execution
|
24
24
|
|
25
25
|
self.tasks.select {|task| task.enabled?}.each do |task|
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
26
|
+
self.task_params(task.name).each do |task_params|
|
27
|
+
task.configure(task_params, self.task_extended_context(task.name))
|
28
|
+
task.before_execute
|
29
|
+
task.execute
|
30
|
+
task.after_execute
|
31
|
+
self.tasks_results << task.report
|
32
|
+
end
|
31
33
|
end
|
32
34
|
|
33
35
|
self.update_results
|
@@ -100,7 +102,7 @@ module Henry
|
|
100
102
|
#
|
101
103
|
# @return [{String => String}] the execution params.
|
102
104
|
def load_params
|
103
|
-
return {} unless File.exists?(self.input_file_path)
|
105
|
+
return [{}] unless File.exists?(self.input_file_path)
|
104
106
|
|
105
107
|
JSON.parse(File.read(self.input_file_path))
|
106
108
|
end
|
@@ -117,9 +119,11 @@ module Henry
|
|
117
119
|
# @note default_params will be used for undefined keys.
|
118
120
|
#
|
119
121
|
# @param [String] task_name the target Task name.
|
120
|
-
# @return [
|
122
|
+
# @return [Array] the Task custom params.
|
121
123
|
def task_params(task_name)
|
122
|
-
self.
|
124
|
+
self.params.collect do |params|
|
125
|
+
(params['all'] || {}).merge(params[task_name] || {})
|
126
|
+
end
|
123
127
|
end
|
124
128
|
|
125
129
|
# Return the default extended execution.
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: henry-container
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.56
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2012-09-
|
12
|
+
date: 2012-09-19 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: rake
|