cucumber 0.2.3 → 0.3.0
Sign up to get free protection for your applications and to get access to all the features.
- data/History.txt +56 -1
- data/Manifest.txt +70 -49
- data/config/hoe.rb +1 -1
- data/cucumber.yml +1 -1
- data/examples/i18n/bg/Rakefile +6 -0
- data/examples/i18n/bg/features/addition.feature +11 -0
- data/examples/i18n/bg/features/consecutive_calculations.feature +18 -0
- data/examples/i18n/bg/features/division.feature +16 -0
- data/examples/i18n/bg/features/step_definitons/calculator_steps.rb +24 -0
- data/examples/i18n/bg/features/support/env.rb +6 -0
- data/examples/i18n/bg/features/support/world.rb +8 -0
- data/examples/i18n/bg/lib/calculator.rb +24 -0
- data/examples/i18n/ru/features/support/world.rb +4 -3
- data/examples/i18n/sk/Rakefile +6 -0
- data/examples/i18n/sk/features/addition.feature +16 -0
- data/examples/i18n/sk/features/division.feature +9 -0
- data/examples/i18n/sk/features/step_definitons/calculator_steps.rb +24 -0
- data/examples/i18n/sk/lib/calculator.rb +14 -0
- data/examples/self_test/features/background/background_with_name.feature +7 -0
- data/examples/self_test/features/background/passing_background.feature +2 -2
- data/examples/self_test/features/step_definitions/sample_steps.rb +18 -2
- data/examples/self_test/features/undefined_multiline_args.feature +12 -0
- data/examples/sinatra/features/support/env.rb +2 -6
- data/examples/test_unit/features/step_definitions/test_unit_steps.rb +1 -4
- data/examples/tickets/Rakefile +1 -1
- data/examples/tickets/features/229/tagged_hooks.feature +8 -0
- data/examples/tickets/features/229/tagged_hooks.rb +14 -0
- data/examples/tickets/features/270/back.feature +14 -0
- data/examples/tickets/features/270/back.steps.rb +14 -0
- data/examples/tickets/features/279/py_string_indent.feature +25 -0
- data/examples/tickets/features/279/py_string_indent.steps.rb +12 -0
- data/examples/tickets/features/279/wrong.feature_ +11 -0
- data/examples/tickets/features/step_definitons/tickets_steps.rb +0 -7
- data/features/background.feature +21 -3
- data/features/cucumber_cli.feature +18 -5
- data/features/cucumber_cli_outlines.feature +4 -1
- data/features/rake_task.feature +132 -0
- data/features/snippet.feature +23 -0
- data/features/step_definitions/cucumber_steps.rb +46 -15
- data/features/support/env.rb +61 -4
- data/features/usage.feature +5 -0
- data/gem_tasks/deployment.rake +1 -1
- data/lib/cucumber/ast/background.rb +14 -4
- data/lib/cucumber/ast/examples.rb +0 -12
- data/lib/cucumber/ast/feature.rb +2 -12
- data/lib/cucumber/ast/feature_element.rb +4 -8
- data/lib/cucumber/ast/features.rb +1 -1
- data/lib/cucumber/ast/outline_table.rb +20 -20
- data/lib/cucumber/ast/py_string.rb +6 -11
- data/lib/cucumber/ast/scenario.rb +1 -8
- data/lib/cucumber/ast/scenario_outline.rb +1 -11
- data/lib/cucumber/ast/step.rb +3 -9
- data/lib/cucumber/ast/step_collection.rb +0 -4
- data/lib/cucumber/ast/step_invocation.rb +5 -6
- data/lib/cucumber/ast/table.rb +5 -22
- data/lib/cucumber/ast/tags.rb +9 -9
- data/lib/cucumber/ast/visitor.rb +12 -25
- data/lib/cucumber/cli/configuration.rb +4 -4
- data/lib/cucumber/cli/main.rb +10 -3
- data/lib/cucumber/core_ext/instance_exec.rb +17 -4
- data/lib/cucumber/formatter/ansicolor.rb +1 -1
- data/lib/cucumber/formatter/console.rb +2 -1
- data/lib/cucumber/formatter/html.rb +21 -7
- data/lib/cucumber/formatter/pretty.rb +27 -20
- data/lib/cucumber/formatter/usage.rb +16 -0
- data/lib/cucumber/languages.yml +23 -5
- data/lib/cucumber/parser/feature.rb +231 -114
- data/lib/cucumber/parser/feature.tt +120 -25
- data/lib/cucumber/parser/table.rb +37 -25
- data/lib/cucumber/parser/table.tt +15 -3
- data/lib/cucumber/parser/treetop_ext.rb +48 -9
- data/lib/cucumber/rake/task.rb +29 -6
- data/lib/cucumber/step_definition.rb +4 -2
- data/lib/cucumber/step_mother.rb +143 -26
- data/lib/cucumber/version.rb +2 -2
- data/rails_generators/cucumber/templates/paths.rb +13 -4
- data/rails_generators/cucumber/templates/webrat_steps.rb +16 -0
- data/{specs → spec}/cucumber/ast/background_spec.rb +1 -0
- data/{specs → spec}/cucumber/ast/feature_factory.rb +1 -1
- data/{specs → spec}/cucumber/ast/feature_spec.rb +2 -2
- data/{specs → spec}/cucumber/ast/py_string_spec.rb +0 -0
- data/{specs → spec}/cucumber/ast/scenario_outline_spec.rb +0 -0
- data/{specs → spec}/cucumber/ast/scenario_spec.rb +0 -27
- data/{specs → spec}/cucumber/ast/step_collection_spec.rb +0 -0
- data/{specs → spec}/cucumber/ast/step_spec.rb +0 -0
- data/{specs → spec}/cucumber/ast/table_spec.rb +2 -2
- data/{specs → spec}/cucumber/broadcaster_spec.rb +0 -0
- data/{specs → spec}/cucumber/cli/configuration_spec.rb +0 -0
- data/{specs → spec}/cucumber/cli/main_spec.rb +5 -1
- data/spec/cucumber/core_ext/proc_spec.rb +54 -0
- data/{specs → spec}/cucumber/core_ext/string_spec.rb +0 -0
- data/{specs → spec}/cucumber/formatter/ansicolor_spec.rb +0 -0
- data/{specs → spec}/cucumber/formatter/color_io_spec.rb +0 -0
- data/{specs → spec}/cucumber/formatter/html/cucumber.css +0 -0
- data/{specs → spec}/cucumber/formatter/html/cucumber.js +0 -0
- data/{specs → spec}/cucumber/formatter/html/index.html +0 -0
- data/{specs → spec}/cucumber/formatter/html/jquery-1.3.min.js +0 -0
- data/{specs → spec}/cucumber/formatter/html/jquery.uitableedit.js +0 -0
- data/{specs → spec}/cucumber/formatters/profile_formatter_spec.rb +0 -0
- data/{specs → spec}/cucumber/parser/feature_parser_spec.rb +43 -41
- data/{specs → spec}/cucumber/parser/table_parser_spec.rb +0 -0
- data/{specs → spec}/cucumber/rails/stubs/mini_rails.rb +0 -0
- data/{specs → spec}/cucumber/rails/stubs/test_help.rb +0 -0
- data/{specs → spec}/cucumber/rails/world_spec.rb +0 -0
- data/{specs → spec}/cucumber/sell_cucumbers.feature +0 -0
- data/{specs → spec}/cucumber/step_definition_spec.rb +0 -0
- data/{specs → spec}/cucumber/step_mother_spec.rb +63 -4
- data/{specs → spec}/cucumber/treetop_parser/empty_feature.feature +0 -0
- data/{specs → spec}/cucumber/treetop_parser/empty_scenario.feature +0 -0
- data/{specs → spec}/cucumber/treetop_parser/empty_scenario_outline.feature +0 -0
- data/{specs → spec}/cucumber/treetop_parser/fit_scenario.feature +0 -0
- data/{specs → spec}/cucumber/treetop_parser/given_scenario.feature +0 -0
- data/{specs → spec}/cucumber/treetop_parser/invalid_scenario_outlines.feature +0 -0
- data/{specs → spec}/cucumber/treetop_parser/multiline_steps.feature +0 -0
- data/{specs → spec}/cucumber/treetop_parser/multiple_tables.feature +0 -0
- data/{specs → spec}/cucumber/treetop_parser/scenario_outline.feature +0 -0
- data/{specs → spec}/cucumber/treetop_parser/spaces.feature +0 -0
- data/{specs → spec}/cucumber/treetop_parser/test_dos.feature +0 -0
- data/{specs → spec}/cucumber/treetop_parser/with_comments.feature +0 -0
- data/{specs → spec}/cucumber/treetop_parser/with_tags.feature +0 -0
- data/{specs → spec}/cucumber/world/pending_spec.rb +0 -0
- data/{specs → spec}/spec.opts +0 -0
- data/{specs → spec}/spec_helper.rb +2 -11
- metadata +72 -51
- data/examples/tickets/cucumber.yml +0 -3
- data/lib/cucumber/parser/basic.rb +0 -0
- data/specs/cucumber/ast/tags_spec.rb +0 -19
- data/specs/cucumber/core_ext/proc_spec.rb +0 -37
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
data/{specs → spec}/spec.opts
RENAMED
File without changes
|
@@ -1,21 +1,12 @@
|
|
1
1
|
require 'rubygems'
|
2
2
|
gem 'rspec'
|
3
|
-
require 'spec
|
3
|
+
require 'spec'
|
4
|
+
require 'spec/autorun'
|
4
5
|
|
5
6
|
ENV['CUCUMBER_COLORS']=nil
|
6
|
-
$KCODE='u'
|
7
7
|
$:.unshift(File.dirname(__FILE__) + '/../lib')
|
8
8
|
require 'cucumber'
|
9
9
|
Cucumber.load_language('en')
|
10
10
|
$:.unshift(File.dirname(__FILE__))
|
11
11
|
|
12
12
|
::Term::ANSIColor.coloring = true
|
13
|
-
|
14
|
-
# Open up the tree classes a little for easier inspection.
|
15
|
-
module Cucumber
|
16
|
-
module Tree
|
17
|
-
class Feature
|
18
|
-
attr_reader :header, :scenarios
|
19
|
-
end
|
20
|
-
end
|
21
|
-
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cucumber
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.3.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- "Aslak Helles\xC3\xB8y"
|
@@ -9,7 +9,7 @@ autorequire:
|
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
11
|
|
12
|
-
date: 2009-
|
12
|
+
date: 2009-04-14 00:00:00 +02:00
|
13
13
|
default_executable:
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
@@ -108,6 +108,14 @@ files:
|
|
108
108
|
- examples/i18n/ar/features/addition.feature
|
109
109
|
- examples/i18n/ar/features/step_definitons/calculator_steps.rb
|
110
110
|
- examples/i18n/ar/lib/calculator.rb
|
111
|
+
- examples/i18n/bg/Rakefile
|
112
|
+
- examples/i18n/bg/features/addition.feature
|
113
|
+
- examples/i18n/bg/features/consecutive_calculations.feature
|
114
|
+
- examples/i18n/bg/features/division.feature
|
115
|
+
- examples/i18n/bg/features/step_definitons/calculator_steps.rb
|
116
|
+
- examples/i18n/bg/features/support/env.rb
|
117
|
+
- examples/i18n/bg/features/support/world.rb
|
118
|
+
- examples/i18n/bg/lib/calculator.rb
|
111
119
|
- examples/i18n/da/Rakefile
|
112
120
|
- examples/i18n/da/features/step_definitons/kalkulator_steps.rb
|
113
121
|
- examples/i18n/da/features/summering.feature
|
@@ -195,6 +203,11 @@ files:
|
|
195
203
|
- examples/i18n/se/features/step_definitons/kalkulator_steps.rb
|
196
204
|
- examples/i18n/se/features/summering.feature
|
197
205
|
- examples/i18n/se/lib/kalkulator.rb
|
206
|
+
- examples/i18n/sk/Rakefile
|
207
|
+
- examples/i18n/sk/features/addition.feature
|
208
|
+
- examples/i18n/sk/features/division.feature
|
209
|
+
- examples/i18n/sk/features/step_definitons/calculator_steps.rb
|
210
|
+
- examples/i18n/sk/lib/calculator.rb
|
198
211
|
- examples/i18n/zh-CN/Rakefile
|
199
212
|
- examples/i18n/zh-CN/features/addition.feature
|
200
213
|
- examples/i18n/zh-CN/features/step_definitons/calculator_steps.rb
|
@@ -222,6 +235,7 @@ files:
|
|
222
235
|
- examples/selenium_webrat/features/support/env.rb
|
223
236
|
- examples/self_test/README.textile
|
224
237
|
- examples/self_test/Rakefile
|
238
|
+
- examples/self_test/features/background/background_with_name.feature
|
225
239
|
- examples/self_test/features/background/failing_background.feature
|
226
240
|
- examples/self_test/features/background/failing_background_after_success.feature
|
227
241
|
- examples/self_test/features/background/multiline_args_background.feature
|
@@ -238,6 +252,7 @@ files:
|
|
238
252
|
- examples/self_test/features/support/env.rb
|
239
253
|
- examples/self_test/features/support/tag_count_formatter.rb
|
240
254
|
- examples/self_test/features/tons_of_cukes.feature
|
255
|
+
- examples/self_test/features/undefined_multiline_args.feature
|
241
256
|
- examples/sinatra/Rakefile
|
242
257
|
- examples/sinatra/app.rb
|
243
258
|
- examples/sinatra/features/add.feature
|
@@ -249,16 +264,22 @@ files:
|
|
249
264
|
- examples/test_unit/features/step_definitions/test_unit_steps.rb
|
250
265
|
- examples/test_unit/features/test_unit.feature
|
251
266
|
- examples/tickets/Rakefile
|
252
|
-
- examples/tickets/cucumber.yml
|
253
267
|
- examples/tickets/features/172.feature
|
254
268
|
- examples/tickets/features/177/1.feature
|
255
269
|
- examples/tickets/features/177/2.feature
|
256
270
|
- examples/tickets/features/177/3.feature
|
257
271
|
- examples/tickets/features/180.feature
|
272
|
+
- examples/tickets/features/229/tagged_hooks.feature
|
273
|
+
- examples/tickets/features/229/tagged_hooks.rb
|
258
274
|
- examples/tickets/features/236.feature
|
259
275
|
- examples/tickets/features/241.feature
|
260
276
|
- examples/tickets/features/246.feature
|
261
277
|
- examples/tickets/features/248.feature
|
278
|
+
- examples/tickets/features/270/back.feature
|
279
|
+
- examples/tickets/features/270/back.steps.rb
|
280
|
+
- examples/tickets/features/279/py_string_indent.feature
|
281
|
+
- examples/tickets/features/279/py_string_indent.steps.rb
|
282
|
+
- examples/tickets/features/279/wrong.feature_
|
262
283
|
- examples/tickets/features/lib/eatting_machine.rb
|
263
284
|
- examples/tickets/features/lib/pantry.rb
|
264
285
|
- examples/tickets/features/scenario_outline.feature
|
@@ -277,7 +298,9 @@ files:
|
|
277
298
|
- features/cucumber_cli_diff_disabled.feature
|
278
299
|
- features/cucumber_cli_outlines.feature
|
279
300
|
- features/custom_formatter.feature
|
301
|
+
- features/rake_task.feature
|
280
302
|
- features/report_called_undefined_steps.feature
|
303
|
+
- features/snippet.feature
|
281
304
|
- features/step_definitions/cucumber_steps.rb
|
282
305
|
- features/step_definitions/extra_steps.rb
|
283
306
|
- features/support/env.rb
|
@@ -338,7 +361,6 @@ files:
|
|
338
361
|
- lib/cucumber/formatters/unicode.rb
|
339
362
|
- lib/cucumber/languages.yml
|
340
363
|
- lib/cucumber/parser.rb
|
341
|
-
- lib/cucumber/parser/basic.rb
|
342
364
|
- lib/cucumber/parser/feature.rb
|
343
365
|
- lib/cucumber/parser/feature.tt
|
344
366
|
- lib/cucumber/parser/i18n.tt
|
@@ -365,53 +387,52 @@ files:
|
|
365
387
|
- rails_generators/feature/feature_generator.rb
|
366
388
|
- rails_generators/feature/templates/feature.erb
|
367
389
|
- rails_generators/feature/templates/steps.erb
|
368
|
-
-
|
369
|
-
-
|
370
|
-
-
|
371
|
-
-
|
372
|
-
-
|
373
|
-
-
|
374
|
-
-
|
375
|
-
-
|
376
|
-
-
|
377
|
-
-
|
378
|
-
-
|
379
|
-
-
|
380
|
-
-
|
381
|
-
-
|
382
|
-
-
|
383
|
-
-
|
384
|
-
-
|
385
|
-
-
|
386
|
-
-
|
387
|
-
-
|
388
|
-
-
|
389
|
-
-
|
390
|
-
-
|
391
|
-
-
|
392
|
-
-
|
393
|
-
-
|
394
|
-
-
|
395
|
-
-
|
396
|
-
-
|
397
|
-
-
|
398
|
-
-
|
399
|
-
-
|
400
|
-
-
|
401
|
-
-
|
402
|
-
-
|
403
|
-
-
|
404
|
-
-
|
405
|
-
-
|
406
|
-
-
|
407
|
-
-
|
408
|
-
-
|
409
|
-
-
|
410
|
-
-
|
411
|
-
-
|
412
|
-
-
|
413
|
-
-
|
414
|
-
- specs/spec_helper.rb
|
390
|
+
- spec/cucumber/ast/background_spec.rb
|
391
|
+
- spec/cucumber/ast/feature_factory.rb
|
392
|
+
- spec/cucumber/ast/feature_spec.rb
|
393
|
+
- spec/cucumber/ast/py_string_spec.rb
|
394
|
+
- spec/cucumber/ast/scenario_outline_spec.rb
|
395
|
+
- spec/cucumber/ast/scenario_spec.rb
|
396
|
+
- spec/cucumber/ast/step_collection_spec.rb
|
397
|
+
- spec/cucumber/ast/step_spec.rb
|
398
|
+
- spec/cucumber/ast/table_spec.rb
|
399
|
+
- spec/cucumber/broadcaster_spec.rb
|
400
|
+
- spec/cucumber/cli/configuration_spec.rb
|
401
|
+
- spec/cucumber/cli/main_spec.rb
|
402
|
+
- spec/cucumber/core_ext/proc_spec.rb
|
403
|
+
- spec/cucumber/core_ext/string_spec.rb
|
404
|
+
- spec/cucumber/formatter/ansicolor_spec.rb
|
405
|
+
- spec/cucumber/formatter/color_io_spec.rb
|
406
|
+
- spec/cucumber/formatter/html/cucumber.css
|
407
|
+
- spec/cucumber/formatter/html/cucumber.js
|
408
|
+
- spec/cucumber/formatter/html/index.html
|
409
|
+
- spec/cucumber/formatter/html/jquery-1.3.min.js
|
410
|
+
- spec/cucumber/formatter/html/jquery.uitableedit.js
|
411
|
+
- spec/cucumber/formatters/profile_formatter_spec.rb
|
412
|
+
- spec/cucumber/parser/feature_parser_spec.rb
|
413
|
+
- spec/cucumber/parser/table_parser_spec.rb
|
414
|
+
- spec/cucumber/rails/stubs/mini_rails.rb
|
415
|
+
- spec/cucumber/rails/stubs/test_help.rb
|
416
|
+
- spec/cucumber/rails/world_spec.rb
|
417
|
+
- spec/cucumber/sell_cucumbers.feature
|
418
|
+
- spec/cucumber/step_definition_spec.rb
|
419
|
+
- spec/cucumber/step_mother_spec.rb
|
420
|
+
- spec/cucumber/treetop_parser/empty_feature.feature
|
421
|
+
- spec/cucumber/treetop_parser/empty_scenario.feature
|
422
|
+
- spec/cucumber/treetop_parser/empty_scenario_outline.feature
|
423
|
+
- spec/cucumber/treetop_parser/fit_scenario.feature
|
424
|
+
- spec/cucumber/treetop_parser/given_scenario.feature
|
425
|
+
- spec/cucumber/treetop_parser/invalid_scenario_outlines.feature
|
426
|
+
- spec/cucumber/treetop_parser/multiline_steps.feature
|
427
|
+
- spec/cucumber/treetop_parser/multiple_tables.feature
|
428
|
+
- spec/cucumber/treetop_parser/scenario_outline.feature
|
429
|
+
- spec/cucumber/treetop_parser/spaces.feature
|
430
|
+
- spec/cucumber/treetop_parser/test_dos.feature
|
431
|
+
- spec/cucumber/treetop_parser/with_comments.feature
|
432
|
+
- spec/cucumber/treetop_parser/with_tags.feature
|
433
|
+
- spec/cucumber/world/pending_spec.rb
|
434
|
+
- spec/spec.opts
|
435
|
+
- spec/spec_helper.rb
|
415
436
|
has_rdoc: true
|
416
437
|
homepage: http://cukes.info
|
417
438
|
post_install_message:
|
File without changes
|
@@ -1,19 +0,0 @@
|
|
1
|
-
require File.dirname(__FILE__) + '/../../spec_helper'
|
2
|
-
|
3
|
-
module Cucumber
|
4
|
-
module Ast
|
5
|
-
describe Tags do
|
6
|
-
before do
|
7
|
-
@tags = Tags.new(-1, %w{one two three})
|
8
|
-
end
|
9
|
-
|
10
|
-
it "should be among other tags" do
|
11
|
-
@tags.should have_tags(%w{one})
|
12
|
-
end
|
13
|
-
|
14
|
-
it "should not be among other tags with irrelevent tag" do
|
15
|
-
@tags.should_not have_tags(%w{bacon})
|
16
|
-
end
|
17
|
-
end
|
18
|
-
end
|
19
|
-
end
|
@@ -1,37 +0,0 @@
|
|
1
|
-
require File.dirname(__FILE__) + '/../../spec_helper'
|
2
|
-
require 'cucumber/core_ext/instance_exec'
|
3
|
-
|
4
|
-
describe Proc do
|
5
|
-
it "should raise ArityMismatchError for too many args (expecting 0)" do
|
6
|
-
lambda {
|
7
|
-
Object.new.cucumber_instance_exec(true, 'foo', 1) do
|
8
|
-
end
|
9
|
-
}.should raise_error(Cucumber::ArityMismatchError, "expected 0 block argument(s), got 1")
|
10
|
-
end
|
11
|
-
|
12
|
-
it "should raise ArityMismatchError for too many args (expecting 1)" do
|
13
|
-
lambda {
|
14
|
-
Object.new.cucumber_instance_exec(true, 'foo', 1,2) do |a|
|
15
|
-
end
|
16
|
-
}.should raise_error(Cucumber::ArityMismatchError, "expected 1 block argument(s), got 2")
|
17
|
-
end
|
18
|
-
|
19
|
-
it "should raise ArityMismatchError for too few args (expecting 1)" do
|
20
|
-
lambda {
|
21
|
-
Object.new.cucumber_instance_exec(true, 'foo') do |a|
|
22
|
-
end
|
23
|
-
}.should raise_error(Cucumber::ArityMismatchError, "expected 1 block argument(s), got 0")
|
24
|
-
end
|
25
|
-
|
26
|
-
it "should raise ArityMismatchError for too few args (expecting 2)" do
|
27
|
-
lambda {
|
28
|
-
Object.new.cucumber_instance_exec(true, 'foo', 1) do |a,b|
|
29
|
-
end
|
30
|
-
}.should raise_error(Cucumber::ArityMismatchError, "expected 2 block argument(s), got 1")
|
31
|
-
end
|
32
|
-
|
33
|
-
it "should remove extraneous path info for file" do
|
34
|
-
proc = lambda {|a,b|}
|
35
|
-
proc.file_colon_line.should == "specs/cucumber/core_ext/proc_spec.rb:34"
|
36
|
-
end
|
37
|
-
end
|