hiptest-publisher 0.15.9 → 0.15.10
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/hiptest-publisher/gherkin_adder.rb +1 -1
- data/lib/hiptest-publisher/nodes.rb +12 -0
- data/lib/hiptest-publisher/render_context_maker.rb +1 -0
- data/lib/hiptest-publisher/renderer.rb +2 -6
- data/lib/templates/cucumber/javascript/_after_hook.hbs +4 -0
- data/lib/templates/cucumber/javascript/_before_hook.hbs +4 -0
- data/lib/templates/cucumber/javascript/actionwords.hbs +3 -1
- metadata +4 -3
- data/lib/templates/cucumber/javascript/_around_hook.hbs +0 -8
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 67f9fb69134dd2a3e084acd9ac614198a9c27a0b
|
4
|
+
data.tar.gz: 18fb9ed4914a371f3f8ca61b15f60f5db51c983e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 268cc8c1076a9cc53158b0c31e461ca6e032874e32260af9735e92a02632494a96922596e3f7f5b46800e98e6b406f19240cfb5a9cf08801219e9bbce855ff3a
|
7
|
+
data.tar.gz: 317d4198410c9d6f1c3d9b950fe3a430c0e67c3bee374b9b261a185f3583fabbf3377fe78020e6a51e579bd91b4828e9c8fb358727ed1f764e77f9e4d511784e
|
@@ -87,7 +87,7 @@ module Hiptest
|
|
87
87
|
result << inline_parameter_name if inline_parameter_name
|
88
88
|
end
|
89
89
|
end
|
90
|
-
missing_parameter_names = actionword_parameters.keys - inline_parameter_names
|
90
|
+
missing_parameter_names = actionword_parameters.keys - inline_parameter_names - ['__free_text']
|
91
91
|
|
92
92
|
patterned = result.join("\"")
|
93
93
|
missing_parameter_names.each do |missing_parameter_name|
|
@@ -203,6 +203,10 @@ module Hiptest
|
|
203
203
|
super()
|
204
204
|
@children = {:name => name, :value => value}
|
205
205
|
end
|
206
|
+
|
207
|
+
def free_text?
|
208
|
+
@children[:name] == "__free_text"
|
209
|
+
end
|
206
210
|
end
|
207
211
|
|
208
212
|
class Call < Node
|
@@ -211,6 +215,10 @@ module Hiptest
|
|
211
215
|
annotation = nil if annotation == ""
|
212
216
|
@children = {:actionword => actionword, :arguments => arguments, :all_arguments => arguments, :annotation => annotation}
|
213
217
|
end
|
218
|
+
|
219
|
+
def free_text_arg
|
220
|
+
children[:arguments].find(&:free_text?)
|
221
|
+
end
|
214
222
|
end
|
215
223
|
|
216
224
|
class IfThen < Node
|
@@ -254,6 +262,10 @@ module Hiptest
|
|
254
262
|
@children[:type].to_s
|
255
263
|
end
|
256
264
|
end
|
265
|
+
|
266
|
+
def free_text?
|
267
|
+
@children[:name] == "__free_text"
|
268
|
+
end
|
257
269
|
end
|
258
270
|
|
259
271
|
class Item < Node
|
@@ -24,12 +24,8 @@ module Hiptest
|
|
24
24
|
|
25
25
|
def walk_call(call)
|
26
26
|
# For Gherkin, we need the __free_text argument rendered.
|
27
|
-
|
28
|
-
|
29
|
-
end.first
|
30
|
-
|
31
|
-
unless free_text_arg.nil?
|
32
|
-
@rendered_children[:free_text_arg] = @rendered[free_text_arg.children[:value]]
|
27
|
+
if call.free_text_arg
|
28
|
+
@rendered_children[:free_text_arg] = @rendered[call.free_text_arg.children[:value]]
|
33
29
|
end
|
34
30
|
|
35
31
|
super(call)
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: hiptest-publisher
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.15.
|
4
|
+
version: 0.15.10
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Hiptest R&D
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-08-
|
11
|
+
date: 2016-08-24 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: colorize
|
@@ -340,7 +340,8 @@ files:
|
|
340
340
|
- lib/templates/cucumber/java/actionword.hbs
|
341
341
|
- lib/templates/cucumber/java/actionwords.hbs
|
342
342
|
- lib/templates/cucumber/java/parameter.hbs
|
343
|
-
- lib/templates/cucumber/javascript/
|
343
|
+
- lib/templates/cucumber/javascript/_after_hook.hbs
|
344
|
+
- lib/templates/cucumber/javascript/_before_hook.hbs
|
344
345
|
- lib/templates/cucumber/javascript/actionword.hbs
|
345
346
|
- lib/templates/cucumber/javascript/actionwords.hbs
|
346
347
|
- lib/templates/cucumber/parameter.hbs
|
@@ -1,8 +0,0 @@
|
|
1
|
-
this.Around(function (scenario, runScenario) {{#curly}}{{#indent}}
|
2
|
-
this.actionwords = Object.create(require('{{{ relative_path './actionwords.js' }}}').Actionwords);
|
3
|
-
runScenario(null, function () {{#curly}}{{#indent}}
|
4
|
-
this.actionwords = null;
|
5
|
-
{{/indent}}
|
6
|
-
{{/curly}});
|
7
|
-
{{/indent}}
|
8
|
-
{{/curly}});
|