rspec-core 2.0.0.beta.22 → 2.0.0.rc

Sign up to get free protection for your applications and to get access to all the features.
Files changed (67) hide show
  1. data/Gemfile +2 -2
  2. data/{History.md → History.markdown} +24 -2
  3. data/Rakefile +1 -0
  4. data/Upgrade.markdown +36 -3
  5. data/bin/rspec +1 -2
  6. data/features/command_line/configure.feature +4 -4
  7. data/features/command_line/example_name_option.feature +17 -3
  8. data/features/command_line/exit_status.feature +13 -28
  9. data/features/command_line/line_number_appended_to_path.feature +12 -16
  10. data/features/command_line/line_number_option.feature +4 -5
  11. data/features/command_line/rake_task.feature +68 -0
  12. data/features/configuration/custom_settings.feature +2 -4
  13. data/features/configuration/fail_fast.feature +77 -0
  14. data/features/configuration/read_options_from_file.feature +2 -5
  15. data/features/example_groups/basic_structure.feature +54 -0
  16. data/features/example_groups/shared_example_group.feature +38 -27
  17. data/features/filtering/exclusion_filters.feature +40 -4
  18. data/features/filtering/inclusion_filters.feature +36 -27
  19. data/features/filtering/run_all_when_everything_filtered.feature +46 -0
  20. data/features/hooks/before_and_after_hooks.feature +21 -1
  21. data/features/pending/pending_examples.feature +24 -5
  22. data/lib/rspec/autorun.rb +2 -0
  23. data/lib/rspec/core.rb +6 -4
  24. data/lib/rspec/core/configuration.rb +69 -23
  25. data/lib/rspec/core/configuration_options.rb +1 -0
  26. data/lib/rspec/core/example.rb +0 -1
  27. data/lib/rspec/core/example_group.rb +23 -8
  28. data/lib/rspec/core/formatters/base_formatter.rb +14 -4
  29. data/lib/rspec/core/formatters/base_text_formatter.rb +2 -0
  30. data/lib/rspec/core/formatters/documentation_formatter.rb +2 -0
  31. data/lib/rspec/core/formatters/progress_formatter.rb +1 -0
  32. data/lib/rspec/core/metadata.rb +18 -11
  33. data/lib/rspec/core/option_parser.rb +6 -1
  34. data/lib/rspec/core/rake_task.rb +10 -10
  35. data/lib/rspec/core/runner.rb +20 -1
  36. data/lib/rspec/core/subject.rb +26 -3
  37. data/lib/rspec/core/version.rb +1 -1
  38. data/lib/rspec/core/world.rb +2 -1
  39. data/spec/autotest/failed_results_re_spec.rb +1 -1
  40. data/spec/rspec/core/configuration_spec.rb +13 -0
  41. data/spec/rspec/core/example_group_spec.rb +107 -26
  42. data/spec/rspec/core/example_spec.rb +11 -24
  43. data/spec/rspec/core/formatters/base_formatter_spec.rb +17 -1
  44. data/spec/rspec/core/formatters/base_text_formatter_spec.rb +6 -5
  45. data/spec/rspec/core/formatters/documentation_formatter_spec.rb +3 -2
  46. data/spec/rspec/core/formatters/html_formatted-1.8.7-jruby.html +25 -22
  47. data/spec/rspec/core/formatters/html_formatted-1.8.7.html +23 -20
  48. data/spec/rspec/core/formatters/html_formatted-1.9.1.html +25 -22
  49. data/spec/rspec/core/formatters/html_formatted-1.9.2.html +25 -2
  50. data/spec/rspec/core/formatters/html_formatter_spec.rb +10 -2
  51. data/spec/rspec/core/formatters/progress_formatter_spec.rb +1 -0
  52. data/spec/rspec/core/formatters/text_mate_formatter_spec.rb +1 -0
  53. data/spec/rspec/core/hooks_filtering_spec.rb +5 -5
  54. data/spec/rspec/core/hooks_spec.rb +4 -4
  55. data/spec/rspec/core/metadata_spec.rb +20 -0
  56. data/spec/rspec/core/option_parser_spec.rb +16 -0
  57. data/spec/rspec/core/rake_task_spec.rb +0 -1
  58. data/spec/rspec/core/reporter_spec.rb +1 -1
  59. data/spec/rspec/core/runner_spec.rb +18 -0
  60. data/spec/rspec/core/shared_example_group_spec.rb +2 -2
  61. data/spec/spec_helper.rb +14 -3
  62. metadata +54 -45
  63. data/.rspec +0 -1
  64. data/features/example_groups/describe_aliases.feature +0 -25
  65. data/features/example_groups/nested_groups.feature +0 -44
  66. data/lib/rspec/core/around_proxy.rb +0 -14
  67. data/lib/rspec/core/formatters.rb +0 -8
data/.rspec DELETED
@@ -1 +0,0 @@
1
- --color
@@ -1,25 +0,0 @@
1
- Feature: Nested example groups
2
-
3
- As an RSpec user
4
- I want to use alternate names for describe
5
- So that I can better organize my examples
6
-
7
- Scenario: Using context
8
- Given a file named "context_instead_of_describe_spec.rb" with:
9
- """
10
- require "rspec/expectations"
11
-
12
- describe "Using context" do
13
- context "with nested context" do
14
- it "should do this" do
15
- true.should be_true
16
- end
17
- end
18
- end
19
- """
20
- When I run "rspec ./context_instead_of_describe_spec.rb -fn"
21
- Then the output should contain:
22
- """
23
- Using context
24
- with nested context
25
- """
@@ -1,44 +0,0 @@
1
- Feature: Nested example groups
2
-
3
- As an RSpec user
4
- I want to nest examples groups
5
- So that I can better organize my examples
6
-
7
- Scenario: Nested example groups
8
- Given a file named "nested_example_groups.rb" with:
9
- """
10
- describe "Some Object" do
11
- describe "with some more context" do
12
- it "should do this" do
13
- true.should be_true
14
- end
15
- end
16
- describe "with some other context" do
17
- it "should do that" do
18
- false.should be_false
19
- end
20
- end
21
- end
22
- """
23
- When I run "rspec nested_example_groups.rb -fdoc"
24
- Then the output should contain "Some Object"
25
- And the output should contain "with some more context"
26
- And the output should contain "with some other context"
27
-
28
- Scenario: failure in outer group continues to run inner groups
29
- Given a file named "nested_example_groups.rb" with:
30
- """
31
- describe "something" do
32
- it "fails" do
33
- raise "failure"
34
- end
35
-
36
- context "nested" do
37
- it "passes" do
38
- end
39
- end
40
- end
41
- """
42
- When I run "rspec nested_example_groups.rb -fdoc"
43
- Then the output should contain "2 examples, 1 failure"
44
- And the output should contain "passes"
@@ -1,14 +0,0 @@
1
- module RSpec
2
- module Core
3
- class AroundProxy
4
- def initialize(example_group_instance, &example_block)
5
- @example_group_instance, @example_block = example_group_instance, example_block
6
- end
7
-
8
- def run
9
- @example_group_instance.instance_eval(&@example_block)
10
- end
11
- end
12
- end
13
- end
14
-
@@ -1,8 +0,0 @@
1
- require 'rspec/core/formatters/helpers'
2
- require 'rspec/core/formatters/base_formatter'
3
- require 'rspec/core/formatters/base_text_formatter'
4
- require 'rspec/core/formatters/documentation_formatter'
5
- require 'rspec/core/formatters/progress_formatter'
6
- require 'rspec/core/formatters/html_formatter'
7
- require 'rspec/core/formatters/text_mate_formatter'
8
-