macros4cuke 0.3.38 → 0.3.39
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
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
---
|
|
2
2
|
!binary "U0hBMQ==":
|
|
3
3
|
metadata.gz: !binary |-
|
|
4
|
-
|
|
4
|
+
M2M1ZDM1NzZiMWZiZDY2ODVjNjhmOGNjMWM1ZmM1ODg4OTU4ZjFhYw==
|
|
5
5
|
data.tar.gz: !binary |-
|
|
6
|
-
|
|
6
|
+
NmRmMGE2MzM4OGZiMjliOGRlNDA2ZWUxNTBiZDAzMTg0ZTdhMjU2NQ==
|
|
7
7
|
!binary "U0hBNTEy":
|
|
8
8
|
metadata.gz: !binary |-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
N2I3ZDlmNzVjYjhlN2U1YjdkODc1YmYzMTI3NmI3NTQ2YTkzYmM1NzU5Njdj
|
|
10
|
+
MDNkZTM0YWFmODc2ZTJlMmY4MjJlYjA3NjZlYzFiZjZkMmE0ZTZjZTk5NzA2
|
|
11
|
+
MjFlNWVkNGU0MTIzNWM0MjRiN2Q5NjVlZDYzZjU1ZmZmNTZlNjg=
|
|
12
12
|
data.tar.gz: !binary |-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
13
|
+
NjQwNmJhZjI2NmMxYjI3YTY5NDBjM2JhOGM3NWMwOTU5ZGFlNGZiYTVlZGFh
|
|
14
|
+
NGM4MWI5MGE0OGZhYzA3MWI1ZmE3Y2FmZmI3OTI1YWViM2Q1YWFlMjNhZDc5
|
|
15
|
+
NTg4MmViMTcwMzRlZmFkYmNlMzNjMGY0MTNiZWY3MzE5YzI5NTQ=
|
data/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
### 0.3.39 / 2013-07-24
|
|
2
|
+
* [CHANGE] File `demo06.feature`: Expanded the comments on the conditional section
|
|
3
|
+
* [CHANGE] File `README.md`: Small editorial changes in the 'A quick section' example.
|
|
4
|
+
|
|
1
5
|
### 0.3.38 / 2013-07-15
|
|
2
6
|
* [FIX] In method AmbiguousArgumentValue#initialize: An method argument was not string-interpolated in the error message.
|
|
3
7
|
* [CHANGE] File 'macro-step_spec.rb' Test updated to cope with the previous fix.
|
data/README.md
CHANGED
|
@@ -18,8 +18,9 @@ __Macros4Cuke__ is a lightweight library that adds a macro facility your Cucumbe
|
|
|
18
18
|
* Familiar syntax for macro-step definitions,
|
|
19
19
|
* Substep sequence can be of arbitrary length,
|
|
20
20
|
* Macro-steps may have data arguments,
|
|
21
|
-
* Data values can be passed to the sub-steps
|
|
22
|
-
*
|
|
21
|
+
* Data values can be passed to the sub-steps,
|
|
22
|
+
* Domain neutral: applicable to any kind of application that can be driven with Cucumber,
|
|
23
|
+
* A group of sub-steps can be made conditional.
|
|
23
24
|
|
|
24
25
|
## A quick example ##
|
|
25
26
|
Here is a macro-step example taken from our demo files:
|
|
@@ -36,18 +37,18 @@ Here is a macro-step example taken from our demo files:
|
|
|
36
37
|
```
|
|
37
38
|
|
|
38
39
|
The first line above specifies the syntax of the macro-step (it is the text between the square brackets).
|
|
39
|
-
Notice also how the arguments _userid_ and _password_ are enclosed between chevrons (angle brackets) <...>.
|
|
40
|
-
Finally, the lines
|
|
40
|
+
Notice also how the macro-step arguments _userid_ and _password_ are enclosed between chevrons (angle brackets) <...>.
|
|
41
|
+
Finally, the text lines between by the triple quotes """ represent the Cucumber steps to execute when
|
|
41
42
|
the macro-step is invoked(used) elsewhere in a feature file.
|
|
42
43
|
|
|
43
44
|
|
|
44
|
-
That macro-step can then be used in a scenario like this:
|
|
45
|
+
That macro-step can then be used/invoked in a scenario like this:
|
|
45
46
|
|
|
46
47
|
```cucumber
|
|
47
48
|
When I [enter my userid "jdoe" and password "hello-world"]
|
|
48
49
|
```
|
|
49
50
|
|
|
50
|
-
Once it is executing, the macro-step
|
|
51
|
+
Once it is executing, the invoked macro-step should be equivalent to:
|
|
51
52
|
|
|
52
53
|
```cucumber
|
|
53
54
|
Given I landed in the homepage
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
# File: macro_support.rb
|
|
2
2
|
# Purpose: Add the support for macros in Cucumber.
|
|
3
3
|
# This file is meant to be put next to the 'env.rb' file
|
|
4
|
-
# of your
|
|
4
|
+
# of your Cucumber project.
|
|
5
5
|
|
|
6
6
|
|
|
7
7
|
# Macros4Cuke step one: Load modules and classes from the gem.
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
# File: macro_support.rb
|
|
3
3
|
# Purpose: Add the support for macros in Cucumber.
|
|
4
4
|
# This file is meant to be put next to the 'env.rb' file
|
|
5
|
-
# of your
|
|
5
|
+
# of your Cucumber project.
|
|
6
6
|
|
|
7
7
|
|
|
8
8
|
# Macros4Cuke step one: Load modules and classes from the gem.
|
data/features/demo06.feature
CHANGED
|
@@ -14,11 +14,17 @@ Scenario: Defining a macro with conditional substeps
|
|
|
14
14
|
And I fill in "zip" with "<postcode>"
|
|
15
15
|
And I fill in "city" with "<city>"
|
|
16
16
|
And I fill in "country" with "<country>"
|
|
17
|
-
|
|
17
|
+
|
|
18
|
+
# Let's assume that the e-mail field is optional.
|
|
19
|
+
# The step between the <?email>...<email> will be executed
|
|
20
|
+
# when the argument <email> has a value assigned to it.
|
|
18
21
|
<?email>
|
|
19
22
|
And I fill in "email" with "<email>"
|
|
20
23
|
</email>
|
|
24
|
+
|
|
21
25
|
# Let's also assume that comment is also optional
|
|
26
|
+
# See the slightly different syntax: the conditional section
|
|
27
|
+
# <?comment>...<comment> may fit in a single line
|
|
22
28
|
<?comment> And I fill in "comment" with "<comment>"</comment>
|
|
23
29
|
And I click "Save"
|
|
24
30
|
"""
|
|
@@ -3,10 +3,10 @@
|
|
|
3
3
|
|
|
4
4
|
module Macros4Cuke # Module used as a namespace
|
|
5
5
|
# The version number of the gem.
|
|
6
|
-
Version = '0.3.
|
|
6
|
+
Version = '0.3.39'
|
|
7
7
|
|
|
8
8
|
# Brief description of the gem.
|
|
9
|
-
Description = '
|
|
9
|
+
Description = 'Macro-steps for Cucumber'
|
|
10
10
|
|
|
11
11
|
# Constant Macros4Cuke::RootDir contains the absolute path of Rodent's
|
|
12
12
|
# root directory. Note: it also ends with a slash character.
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: macros4cuke
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.3.
|
|
4
|
+
version: 0.3.39
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Dimitri Geshef
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2013-07-
|
|
11
|
+
date: 2013-07-24 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: cucumber
|
|
@@ -170,5 +170,5 @@ rubyforge_project:
|
|
|
170
170
|
rubygems_version: 2.0.3
|
|
171
171
|
signing_key:
|
|
172
172
|
specification_version: 4
|
|
173
|
-
summary:
|
|
173
|
+
summary: Macro-steps for Cucumber
|
|
174
174
|
test_files: []
|