cucumber 0.8.6 → 0.8.7
Sign up to get free protection for your applications and to get access to all the features.
- data/.rspec +1 -1
- data/Caliper.yml +4 -0
- data/History.txt +1557 -0
- data/LICENSE +1 -1
- data/README.rdoc +26 -0
- data/Rakefile +51 -5
- data/VERSION.yml +5 -0
- data/bin/cucumber +1 -7
- data/cucumber.gemspec +77 -3
- data/examples/i18n/ar/features/step_definitons/calculator_steps.rb +1 -1
- data/examples/i18n/he/features/step_definitons/calculator_steps.rb +1 -1
- data/examples/i18n/ro/features/step_definitons/calculator_steps.rb +7 -4
- data/examples/i18n/ro/features/suma.feature +11 -0
- data/examples/i18n/ru/features/division.feature +2 -2
- data/examples/i18n/tr/features/step_definitons/hesap_makinesi_adimlari.rb +3 -3
- data/examples/sinatra/features/support/env.rb +5 -2
- data/examples/v8/features/fibonacci.feature +1 -1
- data/examples/watir/features/step_definitions/search_steps.rb +1 -1
- data/features/announce.feature +164 -0
- data/features/around_hooks.feature +232 -0
- data/features/background.feature +95 -284
- data/features/bug_371.feature +32 -0
- data/features/bug_464.feature +16 -0
- data/features/bug_475.feature +42 -0
- data/features/bug_585_tab_indentation.feature +22 -0
- data/features/bug_600.feature +67 -0
- data/features/call_steps_from_stepdefs.feature +154 -0
- data/features/cucumber_cli.feature +591 -0
- data/features/cucumber_cli_outlines.feature +117 -0
- data/features/custom_formatter.feature +73 -3
- data/features/default_snippets.feature +42 -0
- data/features/diffing.feature +25 -0
- data/features/drb_server_integration.feature +174 -0
- data/features/exception_in_after_block.feature +127 -0
- data/features/exception_in_after_step_block.feature +104 -0
- data/features/exception_in_before_block.feature +98 -0
- data/features/exclude_files.feature +20 -0
- data/features/expand.feature +60 -0
- data/features/html_formatter.feature +8 -0
- data/features/html_formatter/a.html +582 -0
- data/features/json_formatter.feature +245 -160
- data/features/junit_formatter.feature +88 -0
- data/features/language_from_header.feature +30 -0
- data/features/language_help.feature +78 -0
- data/features/listener_debugger_formatter.feature +42 -0
- data/features/multiline_names.feature +44 -0
- data/features/negative_tagged_hooks.feature +60 -0
- data/features/post_configuration_hook.feature +37 -0
- data/features/profiles.feature +126 -0
- data/features/rake_task.feature +152 -0
- data/features/report_called_undefined_steps.feature +34 -0
- data/features/rerun_formatter.feature +45 -0
- data/features/simplest.feature +11 -0
- data/features/snippet.feature +23 -0
- data/features/snippets_when_using_star_keyword.feature +36 -0
- data/features/step_definitions/cucumber_steps.rb +153 -7
- data/features/step_definitions/extra_steps.rb +2 -0
- data/features/step_definitions/simplest_steps.rb +3 -0
- data/features/step_definitions/wire_steps.rb +32 -0
- data/features/support/env.rb +140 -18
- data/features/support/env.rb.simplest +7 -0
- data/features/support/fake_wire_server.rb +77 -0
- data/features/table_diffing.feature +45 -0
- data/features/table_mapping.feature +34 -0
- data/features/tag_logic.feature +258 -0
- data/features/transform.feature +245 -0
- data/features/unicode_table.feature +35 -0
- data/features/usage_and_stepdefs_formatter.feature +169 -0
- data/features/wire_protocol.feature +332 -0
- data/features/wire_protocol_table_diffing.feature +119 -0
- data/features/wire_protocol_tags.feature +87 -0
- data/features/wire_protocol_timeouts.feature +63 -0
- data/features/work_in_progress.feature +156 -0
- data/fixtures/json/features/pystring.feature +8 -0
- data/fixtures/junit/features/pending.feature +1 -3
- data/fixtures/self_test/features/background/background_tagged_before_on_outline.feature +12 -0
- data/fixtures/self_test/features/background/background_with_name.feature +7 -0
- data/fixtures/self_test/features/background/failing_background.feature +12 -0
- data/fixtures/self_test/features/background/failing_background_after_success.feature +11 -0
- data/fixtures/self_test/features/background/multiline_args_background.feature +32 -0
- data/fixtures/self_test/features/background/passing_background.feature +10 -0
- data/fixtures/self_test/features/background/pending_background.feature +10 -0
- data/fixtures/self_test/features/background/scenario_outline_failing_background.feature +16 -0
- data/fixtures/self_test/features/background/scenario_outline_passing_background.feature +16 -0
- data/fixtures/self_test/features/support/env.rb +0 -8
- data/fixtures/tickets/features.html +1 -1
- data/gem_tasks/examples.rake +1 -1
- data/gem_tasks/features.rake +14 -0
- data/gem_tasks/sdoc.rake +12 -0
- data/lib/cucumber.rb +0 -12
- data/lib/cucumber/ast.rb +1 -1
- data/lib/cucumber/ast/background.rb +5 -21
- data/lib/cucumber/ast/examples.rb +4 -12
- data/lib/cucumber/ast/feature.rb +5 -13
- data/lib/cucumber/ast/feature_element.rb +4 -9
- data/lib/cucumber/ast/outline_table.rb +4 -4
- data/lib/cucumber/ast/py_string.rb +80 -0
- data/lib/cucumber/ast/scenario.rb +5 -7
- data/lib/cucumber/ast/scenario_outline.rb +15 -23
- data/lib/cucumber/ast/step.rb +0 -5
- data/lib/cucumber/ast/step_invocation.rb +15 -21
- data/lib/cucumber/ast/table.rb +8 -14
- data/lib/cucumber/ast/tree_walker.rb +48 -10
- data/lib/cucumber/cli/configuration.rb +8 -33
- data/lib/cucumber/cli/main.rb +35 -20
- data/lib/cucumber/cli/options.rb +7 -8
- data/lib/cucumber/cli/profile_loader.rb +0 -2
- data/lib/cucumber/core_ext/proc.rb +1 -2
- data/lib/cucumber/feature_file.rb +15 -47
- data/lib/cucumber/formatter/ansicolor.rb +5 -3
- data/lib/cucumber/formatter/color_io.rb +23 -0
- data/lib/cucumber/formatter/console.rb +23 -27
- data/lib/cucumber/formatter/cucumber.css +17 -34
- data/lib/cucumber/formatter/cucumber.sass +182 -173
- data/lib/cucumber/formatter/html.rb +11 -46
- data/lib/cucumber/formatter/io.rb +4 -2
- data/lib/cucumber/formatter/json.rb +152 -15
- data/lib/cucumber/formatter/json_pretty.rb +6 -5
- data/lib/cucumber/formatter/junit.rb +22 -28
- data/lib/cucumber/formatter/pdf.rb +6 -6
- data/lib/cucumber/formatter/pretty.rb +5 -5
- data/lib/cucumber/formatter/rerun.rb +11 -22
- data/lib/cucumber/formatter/tag_cloud.rb +35 -0
- data/lib/cucumber/formatter/unicode.rb +20 -41
- data/lib/cucumber/js_support/js_dsl.js +4 -4
- data/lib/cucumber/js_support/js_language.rb +5 -9
- data/lib/cucumber/js_support/js_snippets.rb +2 -2
- data/lib/cucumber/language_support.rb +2 -2
- data/lib/cucumber/parser/gherkin_builder.rb +30 -35
- data/lib/cucumber/platform.rb +8 -8
- data/lib/cucumber/py_support/py_language.rb +2 -2
- data/lib/cucumber/rake/task.rb +31 -74
- data/lib/cucumber/rb_support/rb_dsl.rb +0 -1
- data/lib/cucumber/rb_support/rb_language.rb +8 -10
- data/lib/cucumber/rb_support/rb_step_definition.rb +0 -8
- data/lib/cucumber/rb_support/rb_transform.rb +0 -17
- data/lib/cucumber/rb_support/rb_world.rb +18 -26
- data/lib/cucumber/rspec/doubles.rb +3 -3
- data/lib/cucumber/step_match.rb +2 -6
- data/lib/cucumber/step_mother.rb +427 -6
- data/lib/cucumber/wire_support/configuration.rb +1 -4
- data/lib/cucumber/wire_support/wire_language.rb +10 -3
- data/spec/cucumber/ast/background_spec.rb +6 -68
- data/spec/cucumber/ast/feature_factory.rb +4 -5
- data/spec/cucumber/ast/feature_spec.rb +4 -4
- data/spec/cucumber/ast/outline_table_spec.rb +1 -1
- data/spec/cucumber/ast/py_string_spec.rb +40 -0
- data/spec/cucumber/ast/scenario_outline_spec.rb +11 -15
- data/spec/cucumber/ast/scenario_spec.rb +4 -4
- data/spec/cucumber/ast/step_spec.rb +3 -3
- data/spec/cucumber/ast/table_spec.rb +2 -38
- data/spec/cucumber/ast/tree_walker_spec.rb +2 -2
- data/spec/cucumber/broadcaster_spec.rb +1 -1
- data/spec/cucumber/cli/configuration_spec.rb +6 -32
- data/spec/cucumber/cli/drb_client_spec.rb +3 -2
- data/spec/cucumber/cli/main_spec.rb +43 -43
- data/spec/cucumber/cli/options_spec.rb +1 -28
- data/spec/cucumber/cli/profile_loader_spec.rb +1 -1
- data/spec/cucumber/core_ext/proc_spec.rb +1 -1
- data/spec/cucumber/formatter/ansicolor_spec.rb +1 -1
- data/spec/cucumber/formatter/color_io_spec.rb +29 -0
- data/spec/cucumber/formatter/duration_spec.rb +1 -1
- data/spec/cucumber/formatter/html_spec.rb +5 -3
- data/spec/cucumber/formatter/junit_spec.rb +2 -16
- data/spec/cucumber/formatter/progress_spec.rb +1 -1
- data/spec/cucumber/formatter/spec_helper.rb +12 -11
- data/spec/cucumber/rb_support/rb_language_spec.rb +28 -241
- data/spec/cucumber/rb_support/rb_step_definition_spec.rb +28 -33
- data/spec/cucumber/rb_support/regexp_argument_matcher_spec.rb +1 -1
- data/spec/cucumber/step_match_spec.rb +9 -11
- data/spec/cucumber/step_mother_spec.rb +302 -0
- data/spec/cucumber/wire_support/configuration_spec.rb +1 -1
- data/spec/cucumber/wire_support/connection_spec.rb +1 -1
- data/spec/cucumber/wire_support/wire_exception_spec.rb +1 -1
- data/spec/cucumber/wire_support/wire_language_spec.rb +1 -1
- data/spec/cucumber/wire_support/wire_packet_spec.rb +1 -1
- data/spec/cucumber/wire_support/wire_step_definition_spec.rb +1 -1
- data/spec/cucumber/world/pending_spec.rb +2 -2
- data/spec/spec_helper.rb +20 -13
- metadata +78 -4
@@ -1,247 +1,256 @@
|
|
1
1
|
/* cucumber.css is generated from cucumber.sass */
|
2
2
|
/* Regenerate with rake sass */
|
3
3
|
|
4
|
-
|
5
|
-
|
4
|
+
!step_left = 5px "solid"
|
5
|
+
!step_bottom = 1px "solid"
|
6
6
|
|
7
|
-
|
8
|
-
|
9
|
-
|
7
|
+
!failed = #FFFBD3
|
8
|
+
!failed_border = #C20000
|
9
|
+
!failed_text = #C20000
|
10
10
|
|
11
|
-
|
12
|
-
|
13
|
-
|
11
|
+
!passed = #DBFFB4
|
12
|
+
!passed_border = #65C400
|
13
|
+
!passed_text = #3D7700
|
14
14
|
|
15
|
-
|
16
|
-
|
17
|
-
|
15
|
+
!skipped = #E0FFFF
|
16
|
+
!skipped_border = #00FFFF
|
17
|
+
!skipped_text = #001111
|
18
18
|
|
19
|
-
|
20
|
-
|
21
|
-
|
19
|
+
!pending = #FCFB98
|
20
|
+
!pending_border = #FAF834
|
21
|
+
!pending_text = #131313
|
22
22
|
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
$message: #e0ffff
|
28
|
-
$message_border: aqua
|
29
|
-
$message_text: #001111
|
23
|
+
!undefined = #FCFB98
|
24
|
+
!undefined_border = #FAF834
|
25
|
+
!undefined_text = #131313
|
30
26
|
|
31
27
|
body
|
32
|
-
font-size
|
33
|
-
color
|
34
|
-
margin
|
35
|
-
padding
|
28
|
+
:font-size 0px
|
29
|
+
:color #FFFFFF
|
30
|
+
:margin 0px
|
31
|
+
:padding 0px
|
36
32
|
|
37
33
|
.cucumber,td,th
|
38
|
-
font
|
39
|
-
background
|
40
|
-
color
|
34
|
+
:font normal 11px "Lucida Grande", Helvetica, sans-serif
|
35
|
+
:background white
|
36
|
+
:color #000000
|
37
|
+
|
41
38
|
#cucumber-header
|
42
|
-
background
|
43
|
-
color
|
44
|
-
height
|
39
|
+
:background #65C400
|
40
|
+
:color #FFFFFF
|
41
|
+
:height 6em
|
42
|
+
|
45
43
|
#expand-collapse
|
46
44
|
p
|
47
|
-
float
|
48
|
-
margin
|
45
|
+
:float right
|
46
|
+
:margin 0 0 0 10px
|
47
|
+
|
49
48
|
.scenario
|
50
49
|
h3
|
51
|
-
font-size
|
52
|
-
padding
|
53
|
-
margin
|
54
|
-
background
|
55
|
-
color
|
56
|
-
font-weight
|
50
|
+
:font-size 11px
|
51
|
+
:padding 3px
|
52
|
+
:margin 0
|
53
|
+
:background #65C400
|
54
|
+
:color #FFFFFF
|
55
|
+
:font-weight bold
|
56
|
+
|
57
57
|
h1
|
58
|
-
margin
|
59
|
-
padding
|
60
|
-
font-family
|
61
|
-
font-size
|
62
|
-
position
|
58
|
+
:margin 0px 10px 0px 10px
|
59
|
+
:padding 10px
|
60
|
+
:font-family "Lucida Grande", Helvetica, sans-serif
|
61
|
+
:font-size 2em
|
62
|
+
:position absolute
|
63
|
+
|
63
64
|
h4
|
64
|
-
margin-bottom
|
65
|
+
:margin-bottom 2px
|
66
|
+
|
65
67
|
div.feature
|
66
|
-
padding
|
67
|
-
margin
|
68
|
+
:padding 2px
|
69
|
+
:margin 0px 10px 5px 10px
|
70
|
+
|
68
71
|
div.examples
|
69
|
-
padding
|
72
|
+
:padding 0em 0em 0em 1em
|
73
|
+
|
70
74
|
.stats
|
71
|
-
margin
|
75
|
+
:margin 2em
|
76
|
+
|
72
77
|
.summary
|
73
78
|
ul.features
|
74
79
|
li
|
75
|
-
display
|
80
|
+
:display inline
|
81
|
+
|
76
82
|
.step_name
|
77
|
-
float
|
83
|
+
:float left
|
84
|
+
|
78
85
|
.step_file
|
79
|
-
text-align
|
80
|
-
color
|
86
|
+
:text-align right
|
87
|
+
:color #999999
|
81
88
|
a
|
82
|
-
color
|
83
|
-
|
84
|
-
|
85
|
-
color: #999999
|
89
|
+
:color #999999
|
90
|
+
|
91
|
+
|
86
92
|
.tag
|
87
|
-
font-weight
|
88
|
-
color
|
93
|
+
:font-weight bold
|
94
|
+
:color #246AC1
|
95
|
+
|
89
96
|
.backtrace
|
90
|
-
margin-top
|
91
|
-
margin-bottom
|
92
|
-
margin-left
|
93
|
-
color
|
97
|
+
:margin-top 0
|
98
|
+
:margin-bottom 0
|
99
|
+
:margin-left 1em
|
100
|
+
:color #000000
|
101
|
+
|
94
102
|
a
|
95
|
-
text-decoration
|
96
|
-
color
|
103
|
+
:text-decoration none
|
104
|
+
:color #BE5C00
|
105
|
+
|
97
106
|
&:hover
|
98
|
-
text-decoration
|
107
|
+
:text-decoration underline
|
99
108
|
&:visited
|
100
|
-
font-weight
|
109
|
+
:font-weight normal
|
110
|
+
|
101
111
|
div.examples
|
102
|
-
margin
|
103
|
-
color
|
112
|
+
:margin 5px 0px 5px 15px
|
113
|
+
:color #000000
|
114
|
+
|
104
115
|
.outline
|
105
116
|
table
|
106
|
-
margin
|
117
|
+
:margin 0px 0px 5px 10px
|
118
|
+
|
107
119
|
table
|
108
|
-
border-collapse
|
120
|
+
:border-collapse collapse
|
109
121
|
td
|
110
|
-
padding
|
122
|
+
:padding 3px 3px 3px 5px
|
111
123
|
td.failed, td.passed, td.skipped, td.pending, td.undefined
|
112
|
-
padding-left
|
113
|
-
padding-right
|
124
|
+
:padding-left 18px
|
125
|
+
:padding-right 10px
|
114
126
|
td.failed
|
115
|
-
border-left
|
116
|
-
border-bottom
|
117
|
-
background
|
118
|
-
color
|
127
|
+
:border-left= !step_left !failed_border
|
128
|
+
:border-bottom= !step_bottom !failed_border
|
129
|
+
:background= !failed
|
130
|
+
:color= !failed_text
|
119
131
|
td.passed
|
120
|
-
border-left
|
121
|
-
border-bottom
|
122
|
-
background
|
123
|
-
color
|
132
|
+
:border-left= !step_left !passed_border
|
133
|
+
:border-bottom= !step_bottom !passed_border
|
134
|
+
:background= !passed
|
135
|
+
:color= !passed_text
|
124
136
|
td.skipped
|
125
|
-
border-left
|
126
|
-
border-bottom
|
127
|
-
background
|
128
|
-
color
|
137
|
+
:border-left= !step_left !skipped_border
|
138
|
+
:border-bottom= !step_bottom !skipped_border
|
139
|
+
:background= !skipped
|
140
|
+
:color= !skipped_text
|
129
141
|
td.pending
|
130
|
-
border-left
|
131
|
-
border-bottom
|
132
|
-
background
|
133
|
-
color
|
142
|
+
:border-left= !step_left !pending_border
|
143
|
+
:border-bottom= !step_bottom !pending_border
|
144
|
+
:background= !pending
|
145
|
+
:color= !pending_text
|
134
146
|
td.undefined
|
135
|
-
border-left
|
136
|
-
border-bottom
|
137
|
-
background
|
138
|
-
color
|
139
|
-
|
140
|
-
border-left: $step_left $message_border
|
141
|
-
border-bottom: $step_bottom $message_border
|
142
|
-
background: $message
|
143
|
-
color: $message_text
|
147
|
+
:border-left= !step_left !undefined_border
|
148
|
+
:border-bottom= !step_bottom !undefined_border
|
149
|
+
:background= !undefined
|
150
|
+
:color= !undefined_text
|
151
|
+
|
144
152
|
ol
|
145
|
-
list-style
|
146
|
-
margin
|
147
|
-
padding
|
153
|
+
:list-style none
|
154
|
+
:margin 0px
|
155
|
+
:padding 0px
|
156
|
+
|
148
157
|
li.step
|
149
|
-
padding
|
150
|
-
margin
|
158
|
+
:padding 3px 3px 3px 18px
|
159
|
+
:margin 5px 0px 5px 5px
|
151
160
|
li
|
152
|
-
margin
|
153
|
-
padding
|
161
|
+
:margin 0em 0em 0em 1em
|
162
|
+
:padding 0em 0em 0em 0.2em
|
154
163
|
span.param
|
155
|
-
font-weight
|
164
|
+
:font-weight bold
|
156
165
|
li.failed
|
157
|
-
border-left
|
158
|
-
border-bottom
|
159
|
-
background
|
160
|
-
color
|
166
|
+
:border-left= !step_left !failed_border
|
167
|
+
:border-bottom= !step_bottom !failed_border
|
168
|
+
:background= !failed
|
169
|
+
:color= !failed_text
|
161
170
|
li.passed
|
162
|
-
border-left
|
163
|
-
border-bottom
|
164
|
-
background
|
165
|
-
color
|
171
|
+
:border-left= !step_left !passed_border
|
172
|
+
:border-bottom= !step_bottom !passed_border
|
173
|
+
:background= !passed
|
174
|
+
:color= !passed_text
|
166
175
|
li.skipped
|
167
|
-
border-left
|
168
|
-
border-bottom
|
169
|
-
background
|
170
|
-
color
|
176
|
+
:border-left= !step_left !skipped_border
|
177
|
+
:border-bottom= !step_bottom !skipped_border
|
178
|
+
:background= !skipped
|
179
|
+
:color= !skipped_text
|
171
180
|
li.pending
|
172
|
-
border-left
|
173
|
-
border-bottom
|
174
|
-
background
|
175
|
-
color
|
181
|
+
:border-left= !step_left !pending_border
|
182
|
+
:border-bottom= !step_bottom !pending_border
|
183
|
+
:background= !pending
|
184
|
+
:color= !pending_text
|
176
185
|
li.undefined
|
177
|
-
border-left
|
178
|
-
border-bottom
|
179
|
-
background
|
180
|
-
color
|
181
|
-
|
182
|
-
border-left: $step_left $message_border
|
183
|
-
border-bottom: $step_bottom $message_border
|
184
|
-
background: $message
|
185
|
-
color: $message_text
|
186
|
-
margin-left: 10px
|
186
|
+
:border-left= !step_left !undefined_border
|
187
|
+
:border-bottom= !step_bottom !undefined_border
|
188
|
+
:background= !undefined
|
189
|
+
:color= !undefined_text
|
190
|
+
|
187
191
|
#summary
|
188
|
-
margin
|
189
|
-
padding
|
190
|
-
text-align
|
191
|
-
top
|
192
|
-
right
|
193
|
-
float
|
192
|
+
:margin 0px
|
193
|
+
:padding 5px 10px
|
194
|
+
:text-align right
|
195
|
+
:top 0px
|
196
|
+
:right 0px
|
197
|
+
:float right
|
198
|
+
|
194
199
|
p
|
195
|
-
margin
|
196
|
-
#totals
|
197
|
-
font-size: 1.2em
|
200
|
+
:margin 0 0 0 2px
|
198
201
|
|
202
|
+
#totals
|
203
|
+
:font-size 1.2em
|
204
|
+
|
199
205
|
.ruby
|
200
|
-
font-size
|
201
|
-
font-family
|
202
|
-
color
|
203
|
-
background
|
204
|
-
padding
|
205
|
-
|
206
|
-
|
206
|
+
:font-size 12px
|
207
|
+
:font-family monospace
|
208
|
+
:color white
|
209
|
+
:background black
|
210
|
+
:padding 0.1em 0 0.2em 0
|
211
|
+
|
212
|
+
.keyword
|
213
|
+
:color #FF6600
|
207
214
|
.constant
|
208
|
-
color
|
215
|
+
:color #339999
|
209
216
|
.attribute
|
210
|
-
color
|
217
|
+
:color white
|
211
218
|
.global
|
212
|
-
color
|
219
|
+
:color white
|
213
220
|
.module
|
214
|
-
color
|
221
|
+
:color white
|
215
222
|
.class
|
216
|
-
color
|
223
|
+
:color white
|
217
224
|
.string
|
218
|
-
color
|
225
|
+
:color #66FF00
|
219
226
|
.ident
|
220
|
-
color
|
227
|
+
:color white
|
221
228
|
.method
|
222
|
-
color
|
229
|
+
:color #FFCC00
|
223
230
|
.number
|
224
|
-
color
|
231
|
+
:color white
|
225
232
|
.char
|
226
|
-
color
|
233
|
+
:color white
|
227
234
|
.comment
|
228
|
-
color
|
235
|
+
:color #9933CC
|
229
236
|
.symbol
|
230
|
-
color
|
237
|
+
:color white
|
231
238
|
.regex
|
232
|
-
color
|
239
|
+
:color #44B4CC
|
233
240
|
.punct
|
234
|
-
color
|
241
|
+
:color white
|
235
242
|
.escape
|
236
|
-
color
|
237
|
-
.interp
|
238
|
-
color
|
239
|
-
.expr
|
240
|
-
color
|
243
|
+
:color white
|
244
|
+
.interp
|
245
|
+
:color white
|
246
|
+
.expr
|
247
|
+
:color white
|
248
|
+
|
241
249
|
.offending
|
242
|
-
background
|
250
|
+
:background #333333
|
243
251
|
.linenum
|
244
|
-
width
|
245
|
-
padding
|
246
|
-
color
|
247
|
-
background
|
252
|
+
:width 75px
|
253
|
+
:padding 0.1em 1em 0.2em 0
|
254
|
+
:color #000000
|
255
|
+
:background #FFFBD3
|
256
|
+
|
@@ -20,23 +20,20 @@ module Cucumber
|
|
20
20
|
@scenario_number = 0
|
21
21
|
@step_number = 0
|
22
22
|
@header_red = nil
|
23
|
-
@delayed_messages = []
|
24
|
-
@img_id = 0
|
25
23
|
end
|
26
24
|
|
27
|
-
def embed(
|
25
|
+
def embed(file, mime_type)
|
28
26
|
case(mime_type)
|
29
27
|
when /^image\/(png|gif|jpg|jpeg)/
|
30
|
-
embed_image(
|
28
|
+
embed_image(file)
|
31
29
|
end
|
32
30
|
end
|
33
31
|
|
34
|
-
def embed_image(
|
35
|
-
id =
|
36
|
-
@img_id += 1
|
32
|
+
def embed_image(file)
|
33
|
+
id = file.hash
|
37
34
|
@builder.span(:class => 'embed') do |pre|
|
38
|
-
pre << %{<a href="" onclick="img=document.getElementById('#{id}'); img.style.display = (img.style.display == 'none' ? 'block' : 'none');return false"
|
39
|
-
<img id="#{id}" style="display: none" src="#{
|
35
|
+
pre << %{<a href="" onclick="img=document.getElementById('#{id}'); img.style.display = (img.style.display == 'none' ? 'block' : 'none');return false">Screenshot</a><br>
|
36
|
+
<img id="#{id}" style="display: none" src="#{file}"/>}
|
40
37
|
end
|
41
38
|
end
|
42
39
|
|
@@ -166,9 +163,6 @@ module Cucumber
|
|
166
163
|
end
|
167
164
|
|
168
165
|
def scenario_name(keyword, name, file_colon_line, source_indent)
|
169
|
-
@builder.span(:class => 'scenario_file') do
|
170
|
-
@builder << file_colon_line
|
171
|
-
end
|
172
166
|
@listing_background = false
|
173
167
|
@builder.h3(:id => "scenario_#{@scenario_number}") do
|
174
168
|
@builder.span(keyword + ':', :class => 'keyword')
|
@@ -251,7 +245,6 @@ module Cucumber
|
|
251
245
|
end
|
252
246
|
end
|
253
247
|
@builder << '</li>'
|
254
|
-
print_messages
|
255
248
|
end
|
256
249
|
|
257
250
|
def step_name(keyword, step_match, status, source_indent, background)
|
@@ -288,7 +281,7 @@ module Cucumber
|
|
288
281
|
end
|
289
282
|
end
|
290
283
|
|
291
|
-
def
|
284
|
+
def py_string(string)
|
292
285
|
return if @hide_this_step
|
293
286
|
@builder.pre(:class => 'val') do |pre|
|
294
287
|
@builder << string.gsub("\n", '
')
|
@@ -305,7 +298,6 @@ module Cucumber
|
|
305
298
|
|
306
299
|
def after_table_row(table_row)
|
307
300
|
return if @hide_this_step
|
308
|
-
print_table_row_messages
|
309
301
|
@builder << '</tr>'
|
310
302
|
if table_row.exception
|
311
303
|
@builder.tr do
|
@@ -335,35 +327,8 @@ module Cucumber
|
|
335
327
|
@col_index += 1
|
336
328
|
end
|
337
329
|
|
338
|
-
def
|
339
|
-
@
|
340
|
-
#@builder.pre(message, :class => 'message')
|
341
|
-
end
|
342
|
-
|
343
|
-
def print_messages
|
344
|
-
return if @delayed_messages.empty?
|
345
|
-
|
346
|
-
#@builder.ol do
|
347
|
-
@delayed_messages.each do |ann|
|
348
|
-
@builder.li(:class => 'step message') do
|
349
|
-
@builder << ann
|
350
|
-
end
|
351
|
-
end
|
352
|
-
#end
|
353
|
-
empty_messages
|
354
|
-
end
|
355
|
-
|
356
|
-
def print_table_row_messages
|
357
|
-
return if @delayed_messages.empty?
|
358
|
-
|
359
|
-
@builder.td(:class => 'message') do
|
360
|
-
@builder << @delayed_messages.join(", ")
|
361
|
-
end
|
362
|
-
empty_messages
|
363
|
-
end
|
364
|
-
|
365
|
-
def empty_messages
|
366
|
-
@delayed_messages = []
|
330
|
+
def announce(announcement)
|
331
|
+
@builder.pre(announcement, :class => 'announcement')
|
367
332
|
end
|
368
333
|
|
369
334
|
protected
|
@@ -393,7 +358,7 @@ module Cucumber
|
|
393
358
|
end
|
394
359
|
|
395
360
|
def set_scenario_color(status)
|
396
|
-
if status == :undefined
|
361
|
+
if status == :undefined
|
397
362
|
set_scenario_color_pending
|
398
363
|
end
|
399
364
|
if status == :failed
|
@@ -558,7 +523,7 @@ module Cucumber
|
|
558
523
|
end
|
559
524
|
|
560
525
|
def backtrace_line(line)
|
561
|
-
line.gsub(
|
526
|
+
line.gsub(/^([^:]*\.(?:rb|feature|haml)):(\d*)/) do
|
562
527
|
if ENV['TM_PROJECT_DIRECTORY']
|
563
528
|
"<a href=\"txmt://open?url=file://#{File.expand_path($1)}&line=#{$2}\">#{$1}:#{$2}</a> "
|
564
529
|
else
|