square-cucumber 0.3.12.2 → 0.3.93.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (91) hide show
  1. data/History.txt +117 -4
  2. data/Manifest.txt +11 -0
  3. data/Rakefile +1 -1
  4. data/config/hoe.rb +3 -2
  5. data/cucumber.yml +2 -2
  6. data/examples/i18n/ko/features/addition.feature +5 -5
  7. data/examples/i18n/ko/features/step_definitons/calculator_steps.rb +1 -1
  8. data/examples/i18n/no/features/step_definitons/kalkulator_steps.rb +1 -1
  9. data/examples/i18n/pt/features/adicao.feature +4 -4
  10. data/examples/self_test/features/support/env.rb +2 -1
  11. data/examples/sinatra/features/support/env.rb +7 -1
  12. data/examples/steps_library/features/step_definitions/steps_lib1.rb +8 -0
  13. data/examples/steps_library/features/step_definitions/steps_lib2.rb +8 -0
  14. data/examples/tickets/features/step_definitons/tickets_steps.rb +15 -0
  15. data/examples/tickets/features/table_diffing.feature +13 -0
  16. data/examples/watir/features/step_definitons/search_steps.rb +5 -1
  17. data/features/cucumber_cli_diff_disabled.feature +2 -1
  18. data/features/html_formatter/a.html +5 -7
  19. data/features/junit_formatter.feature +21 -14
  20. data/features/profiles.feature +99 -0
  21. data/features/rake_task.feature +28 -0
  22. data/features/step_definitions/cucumber_steps.rb +28 -15
  23. data/features/steps_formatter.feature +25 -0
  24. data/features/support/env.rb +9 -5
  25. data/features/table_diffing.feature +45 -0
  26. data/features/unicode_table.feature +35 -0
  27. data/features/work_in_progress.feature +1 -0
  28. data/gem_tasks/contributors.rake +4 -0
  29. data/lib/cucumber/ast/background.rb +1 -0
  30. data/lib/cucumber/ast/comment.rb +1 -0
  31. data/lib/cucumber/ast/examples.rb +1 -0
  32. data/lib/cucumber/ast/feature.rb +10 -0
  33. data/lib/cucumber/ast/features.rb +6 -1
  34. data/lib/cucumber/ast/outline_table.rb +4 -1
  35. data/lib/cucumber/ast/py_string.rb +1 -1
  36. data/lib/cucumber/ast/scenario.rb +1 -0
  37. data/lib/cucumber/ast/scenario_outline.rb +2 -0
  38. data/lib/cucumber/ast/step.rb +5 -1
  39. data/lib/cucumber/ast/step_collection.rb +1 -0
  40. data/lib/cucumber/ast/step_invocation.rb +1 -0
  41. data/lib/cucumber/ast/table.rb +306 -52
  42. data/lib/cucumber/ast/tags.rb +1 -0
  43. data/lib/cucumber/ast/visitor.rb +2 -1
  44. data/lib/cucumber/cli/configuration.rb +28 -278
  45. data/lib/cucumber/cli/drb_client.rb +3 -1
  46. data/lib/cucumber/cli/language_help_formatter.rb +9 -7
  47. data/lib/cucumber/cli/main.rb +16 -2
  48. data/lib/cucumber/cli/options.rb +370 -0
  49. data/lib/cucumber/cli/profile_loader.rb +65 -0
  50. data/lib/cucumber/core_ext/instance_exec.rb +8 -5
  51. data/lib/cucumber/feature_file.rb +7 -1
  52. data/lib/cucumber/filter.rb +2 -2
  53. data/lib/cucumber/formatter/ansicolor.rb +42 -9
  54. data/lib/cucumber/formatter/console.rb +1 -1
  55. data/lib/cucumber/formatter/html.rb +12 -10
  56. data/lib/cucumber/formatter/junit.rb +63 -26
  57. data/lib/cucumber/formatter/pretty.rb +20 -5
  58. data/lib/cucumber/formatter/progress.rb +1 -1
  59. data/lib/cucumber/formatter/steps.rb +49 -0
  60. data/lib/cucumber/languages.yml +6 -6
  61. data/lib/cucumber/parser/feature.rb +90 -63
  62. data/lib/cucumber/parser/feature.tt +28 -1
  63. data/lib/cucumber/parser/i18n/language.rb +12 -5
  64. data/lib/cucumber/parser/table.rb +25 -25
  65. data/lib/cucumber/rake/task.rb +9 -3
  66. data/lib/cucumber/step_definition.rb +1 -1
  67. data/lib/cucumber/step_match.rb +1 -1
  68. data/lib/cucumber/step_mother.rb +3 -1
  69. data/lib/cucumber/version.rb +2 -2
  70. data/lib/cucumber/webrat/table_locator.rb +66 -0
  71. data/rails_generators/cucumber/cucumber_generator.rb +5 -1
  72. data/rails_generators/cucumber/templates/cucumber +3 -2
  73. data/rails_generators/cucumber/templates/cucumber.rake +18 -6
  74. data/rails_generators/cucumber/templates/cucumber_environment.rb +7 -4
  75. data/rails_generators/cucumber/templates/env.rb +1 -0
  76. data/rails_generators/cucumber/templates/spork_env.rb +1 -0
  77. data/rails_generators/cucumber/templates/webrat_steps.rb +22 -0
  78. data/rails_generators/feature/templates/feature.erb +1 -1
  79. data/rails_generators/feature/templates/steps.erb +2 -8
  80. data/spec/cucumber/ast/table_spec.rb +169 -0
  81. data/spec/cucumber/cli/configuration_spec.rb +144 -101
  82. data/spec/cucumber/cli/main_spec.rb +14 -5
  83. data/spec/cucumber/cli/options_spec.rb +311 -0
  84. data/spec/cucumber/cli/profile_loader_spec.rb +10 -0
  85. data/spec/cucumber/core_ext/proc_spec.rb +16 -2
  86. data/spec/cucumber/formatter/html_spec.rb +18 -0
  87. data/spec/cucumber/formatter/progress_spec.rb +2 -2
  88. data/spec/cucumber/parser/table_parser_spec.rb +1 -1
  89. data/spec/spec.opts +3 -1
  90. metadata +18 -4
  91. data/lib/cucumber/webrat/mechanize_world.rb +0 -82
data/spec/spec.opts CHANGED
@@ -1,2 +1,4 @@
1
1
  --colour
2
- --diff
2
+ --format
3
+ profile
4
+ --diff
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: square-cucumber
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.12.2
4
+ version: 0.3.93.1
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-06-16 00:00:00 -07:00
12
+ date: 2009-08-03 00:00:00 -07:00
13
13
  default_executable: cucumber
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
@@ -30,7 +30,7 @@ dependencies:
30
30
  requirements:
31
31
  - - ">="
32
32
  - !ruby/object:Gem::Version
33
- version: 1.2.6
33
+ version: 1.3.0
34
34
  version:
35
35
  - !ruby/object:Gem::Dependency
36
36
  name: diff-lcs
@@ -272,6 +272,8 @@ files:
272
272
  - examples/sinatra/features/support/env.rb
273
273
  - examples/sinatra/views/add.erb
274
274
  - examples/sinatra/views/layout.erb
275
+ - examples/steps_library/features/step_definitions/steps_lib1.rb
276
+ - examples/steps_library/features/step_definitions/steps_lib2.rb
275
277
  - examples/test_unit/Rakefile
276
278
  - examples/test_unit/features/step_definitions/test_unit_steps.rb
277
279
  - examples/test_unit/features/test_unit.feature
@@ -304,6 +306,7 @@ files:
304
306
  - examples/tickets/features/step_definitons/248_steps.rb
305
307
  - examples/tickets/features/step_definitons/scenario_outline_steps.rb
306
308
  - examples/tickets/features/step_definitons/tickets_steps.rb
309
+ - examples/tickets/features/table_diffing.feature
307
310
  - examples/tickets/features/tickets.feature
308
311
  - examples/watir/README.textile
309
312
  - examples/watir/Rakefile
@@ -326,14 +329,19 @@ files:
326
329
  - features/junit_formatter.feature
327
330
  - features/language_from_header.feature
328
331
  - features/multiline_names.feature
332
+ - features/profiles.feature
329
333
  - features/rake_task.feature
330
334
  - features/report_called_undefined_steps.feature
331
335
  - features/snippet.feature
332
336
  - features/step_definitions/cucumber_steps.rb
333
337
  - features/step_definitions/extra_steps.rb
338
+ - features/steps_formatter.feature
334
339
  - features/support/env.rb
340
+ - features/table_diffing.feature
341
+ - features/unicode_table.feature
335
342
  - features/usage.feature
336
343
  - features/work_in_progress.feature
344
+ - gem_tasks/contributors.rake
337
345
  - gem_tasks/deployment.rake
338
346
  - gem_tasks/environment.rake
339
347
  - gem_tasks/features.rake
@@ -372,6 +380,8 @@ files:
372
380
  - lib/cucumber/cli/drb_client.rb
373
381
  - lib/cucumber/cli/language_help_formatter.rb
374
382
  - lib/cucumber/cli/main.rb
383
+ - lib/cucumber/cli/options.rb
384
+ - lib/cucumber/cli/profile_loader.rb
375
385
  - lib/cucumber/core_ext/exception.rb
376
386
  - lib/cucumber/core_ext/instance_exec.rb
377
387
  - lib/cucumber/core_ext/proc.rb
@@ -390,6 +400,7 @@ files:
390
400
  - lib/cucumber/formatter/profile.rb
391
401
  - lib/cucumber/formatter/progress.rb
392
402
  - lib/cucumber/formatter/rerun.rb
403
+ - lib/cucumber/formatter/steps.rb
393
404
  - lib/cucumber/formatter/tag_cloud.rb
394
405
  - lib/cucumber/formatter/unicode.rb
395
406
  - lib/cucumber/formatter/usage.rb
@@ -408,11 +419,11 @@ files:
408
419
  - lib/cucumber/rails/world.rb
409
420
  - lib/cucumber/rake/task.rb
410
421
  - lib/cucumber/rspec_neuter.rb
411
- - lib/cucumber/webrat/mechanize_world.rb
412
422
  - lib/cucumber/step_definition.rb
413
423
  - lib/cucumber/step_match.rb
414
424
  - lib/cucumber/step_mother.rb
415
425
  - lib/cucumber/version.rb
426
+ - lib/cucumber/webrat/table_locator.rb
416
427
  - lib/cucumber/world.rb
417
428
  - rails_generators/cucumber/USAGE
418
429
  - rails_generators/cucumber/cucumber_generator.rb
@@ -442,11 +453,14 @@ files:
442
453
  - spec/cucumber/cli/configuration_spec.rb
443
454
  - spec/cucumber/cli/drb_client_spec.rb
444
455
  - spec/cucumber/cli/main_spec.rb
456
+ - spec/cucumber/cli/options_spec.rb
457
+ - spec/cucumber/cli/profile_loader_spec.rb
445
458
  - spec/cucumber/core_ext/proc_spec.rb
446
459
  - spec/cucumber/core_ext/string_spec.rb
447
460
  - spec/cucumber/formatter/ansicolor_spec.rb
448
461
  - spec/cucumber/formatter/color_io_spec.rb
449
462
  - spec/cucumber/formatter/duration_spec.rb
463
+ - spec/cucumber/formatter/html_spec.rb
450
464
  - spec/cucumber/formatter/progress_spec.rb
451
465
  - spec/cucumber/parser/feature_parser_spec.rb
452
466
  - spec/cucumber/parser/table_parser_spec.rb
@@ -1,82 +0,0 @@
1
- # Test through HTTP using Mechanize.
2
-
3
- begin
4
- require 'test/unit'
5
- rescue LoadError => e
6
- e.message << "\nYou must gem install test-unit. For more info see https://rspec.lighthouseapp.com/projects/16211/tickets/292"
7
- e.message << "\nAlso make sure you have rack 1.0.0 or higher."
8
- raise e
9
- end
10
-
11
- begin
12
- require 'www/mechanize'
13
- rescue LoadError => e
14
- e.message << "\nYou must gem install mechanize."
15
- raise e
16
- end
17
-
18
- require 'webrat'
19
- require 'webrat/core/matchers'
20
-
21
- Webrat.configure do |config|
22
- config.mode = :mechanize
23
- end
24
-
25
- module WWW #:nodoc:
26
- class Mechanize
27
- def self.log_disabled
28
- @@log ||= Logger.new(STDOUT)
29
- end
30
-
31
- class File
32
- attr_accessor :redirects
33
-
34
- def redirect?
35
- redirects > 0
36
- end
37
-
38
- def response_code
39
- code.to_i
40
- end
41
-
42
- def error?
43
- (500..599).include?(response_code)
44
- end
45
-
46
- def success?
47
- (200..299).include?(response_code)
48
- end
49
-
50
- def unauthorized?
51
- response_code == 401
52
- end
53
- end
54
-
55
- # Mechanize throws exceptions for certain HTTP status codes.
56
- # We want to catch these and still create a page.
57
- def fetch_page_with_secret_sauce(params)
58
- begin
59
- page = fetch_page_without_secret_sauce(params)
60
- rescue ResponseCodeError => e
61
- page = e.page
62
- end
63
- page.redirects ||= params[:redirects].to_i
64
- page
65
- end
66
- alias_method :fetch_page_without_secret_sauce, :fetch_page
67
- alias_method :fetch_page, :fetch_page_with_secret_sauce
68
- end
69
- end
70
-
71
- module Cucumber #:nodoc:
72
- module Webrat
73
- class MechanizeWorld < ::Webrat::MechanizeSession
74
- include ::Test::Unit::Assertions
75
- include ::Webrat::Matchers
76
- end
77
- end
78
- end
79
-
80
- World do
81
- Cucumber::Webrat::MechanizeWorld.new
82
- end