dchelimsky-rspec 1.1.10 → 1.1.11

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.
Files changed (120) hide show
  1. data/History.txt +17 -0
  2. data/Manifest.txt +53 -74
  3. data/Rakefile +0 -1
  4. data/examples/{pure → passing}/autogenerated_docstrings_example.rb +6 -0
  5. data/examples/{pure → passing}/before_and_after_example.rb +0 -0
  6. data/examples/{pure → passing}/behave_as_example.rb +0 -0
  7. data/examples/{pure → passing}/custom_expectation_matchers.rb +0 -0
  8. data/examples/{pure → passing}/custom_formatter.rb +1 -1
  9. data/examples/{pure → passing}/dynamic_spec.rb +2 -2
  10. data/examples/{pure → passing}/file_accessor.rb +0 -0
  11. data/examples/{pure → passing}/file_accessor_spec.rb +0 -0
  12. data/examples/{pure → passing}/greeter_spec.rb +0 -0
  13. data/examples/{pure → passing}/helper_method_example.rb +0 -0
  14. data/examples/{pure → passing}/io_processor.rb +0 -0
  15. data/examples/{pure → passing}/io_processor_spec.rb +0 -0
  16. data/examples/{pure → passing}/legacy_spec.rb +0 -0
  17. data/examples/{pure → passing}/mocking_example.rb +0 -0
  18. data/examples/{pure → passing}/multi_threaded_behaviour_runner.rb +0 -0
  19. data/examples/{pure → passing}/nested_classes_example.rb +0 -0
  20. data/examples/{pure → passing}/partial_mock_example.rb +0 -0
  21. data/examples/{pure → passing}/pending_example.rb +0 -0
  22. data/examples/{pure → passing}/predicate_example.rb +0 -0
  23. data/examples/{pure → passing}/priority.txt +0 -0
  24. data/examples/{pure → passing}/shared_example_group_example.rb +0 -0
  25. data/examples/{pure → passing}/shared_stack_examples.rb +1 -3
  26. data/examples/{pure → passing}/spec_helper.rb +0 -0
  27. data/examples/{pure → passing}/stack.rb +0 -0
  28. data/examples/{pure → passing}/stack_spec.rb +3 -2
  29. data/examples/{pure → passing}/stack_spec_with_nested_example_groups.rb +0 -0
  30. data/examples/{pure → passing}/stubbing_example.rb +0 -0
  31. data/examples/{pure → passing}/yielding_example.rb +0 -0
  32. data/lib/spec/example/before_and_after_hooks.rb +8 -21
  33. data/lib/spec/example/configuration.rb +45 -45
  34. data/lib/spec/example/example_group_factory.rb +10 -9
  35. data/lib/spec/example/example_group_methods.rb +31 -15
  36. data/lib/spec/example/example_methods.rb +74 -22
  37. data/lib/spec/example/shared_example_group.rb +27 -16
  38. data/lib/spec/example.rb +28 -0
  39. data/lib/spec/expectations.rb +1 -0
  40. data/lib/spec/extensions.rb +0 -2
  41. data/lib/spec/matchers/be.rb +96 -114
  42. data/lib/spec/matchers/operator_matcher.rb +2 -9
  43. data/lib/spec/matchers/throw_symbol.rb +41 -15
  44. data/lib/spec/matchers.rb +4 -27
  45. data/lib/spec/runner/formatter/base_text_formatter.rb +1 -1
  46. data/lib/spec/runner/option_parser.rb +2 -2
  47. data/lib/spec/runner/reporter.rb +1 -1
  48. data/lib/spec/runner.rb +1 -1
  49. data/lib/spec/version.rb +1 -1
  50. data/lib/spec.rb +1 -0
  51. data/rspec.gemspec +4 -24
  52. data/spec/spec/example/example_group_factory_spec.rb +29 -9
  53. data/spec/spec/example/example_group_methods_spec.rb +4 -6
  54. data/spec/spec/example/example_group_spec.rb +0 -6
  55. data/spec/spec/example/example_matcher_spec.rb +6 -23
  56. data/spec/spec/example/example_methods_spec.rb +117 -2
  57. data/spec/spec/example/shared_example_group_spec.rb +51 -75
  58. data/spec/spec/matchers/be_spec.rb +40 -7
  59. data/spec/spec/matchers/description_generation_spec.rb +14 -0
  60. data/spec/spec/matchers/throw_symbol_spec.rb +83 -41
  61. data/spec/spec/runner/command_line_spec.rb +4 -4
  62. data/spec/spec/runner/formatter/html_formatted-1.8.4.html +6 -6
  63. data/spec/spec/runner/formatter/html_formatted-1.8.5-jruby.html +9 -9
  64. data/spec/spec/runner/formatter/html_formatted-1.8.5.html +6 -6
  65. data/spec/spec/runner/formatter/html_formatted-1.8.6-jruby.html +10 -10
  66. data/spec/spec/runner/formatter/html_formatted-1.8.6.html +6 -6
  67. data/spec/spec/runner/formatter/html_formatter_spec.rb +1 -1
  68. data/spec/spec/runner/formatter/spec_mate_formatter_spec.rb +5 -5
  69. data/spec/spec/runner/formatter/text_mate_formatted-1.8.4.html +6 -6
  70. data/spec/spec/runner/formatter/text_mate_formatted-1.8.6.html +6 -6
  71. data/spec/spec/runner/reporter_spec.rb +1 -1
  72. data/stories/example_groups/autogenerated_docstrings +4 -4
  73. data/stories/example_groups/nested_groups +2 -2
  74. metadata +33 -59
  75. data/examples/stories/adder.rb +0 -13
  76. data/examples/stories/addition +0 -34
  77. data/examples/stories/addition.rb +0 -9
  78. data/examples/stories/calculator.rb +0 -65
  79. data/examples/stories/game-of-life/.loadpath +0 -5
  80. data/examples/stories/game-of-life/README.txt +0 -21
  81. data/examples/stories/game-of-life/behaviour/everything.rb +0 -6
  82. data/examples/stories/game-of-life/behaviour/examples/examples.rb +0 -3
  83. data/examples/stories/game-of-life/behaviour/examples/game_behaviour.rb +0 -35
  84. data/examples/stories/game-of-life/behaviour/examples/grid_behaviour.rb +0 -66
  85. data/examples/stories/game-of-life/behaviour/stories/CellsWithLessThanTwoNeighboursDie.story +0 -21
  86. data/examples/stories/game-of-life/behaviour/stories/CellsWithMoreThanThreeNeighboursDie.story +0 -21
  87. data/examples/stories/game-of-life/behaviour/stories/EmptySpacesWithThreeNeighboursCreateACell.story +0 -42
  88. data/examples/stories/game-of-life/behaviour/stories/ICanCreateACell.story +0 -42
  89. data/examples/stories/game-of-life/behaviour/stories/ICanKillACell.story +0 -17
  90. data/examples/stories/game-of-life/behaviour/stories/TheGridWraps.story +0 -53
  91. data/examples/stories/game-of-life/behaviour/stories/create_a_cell.rb +0 -52
  92. data/examples/stories/game-of-life/behaviour/stories/helper.rb +0 -6
  93. data/examples/stories/game-of-life/behaviour/stories/kill_a_cell.rb +0 -26
  94. data/examples/stories/game-of-life/behaviour/stories/steps.rb +0 -5
  95. data/examples/stories/game-of-life/behaviour/stories/stories.rb +0 -3
  96. data/examples/stories/game-of-life/behaviour/stories/stories.txt +0 -22
  97. data/examples/stories/game-of-life/life/game.rb +0 -23
  98. data/examples/stories/game-of-life/life/grid.rb +0 -43
  99. data/examples/stories/game-of-life/life.rb +0 -3
  100. data/examples/stories/helper.rb +0 -9
  101. data/examples/stories/steps/addition_steps.rb +0 -18
  102. data/failing_examples/README.txt +0 -7
  103. data/failing_examples/diffing_spec.rb +0 -36
  104. data/failing_examples/failing_autogenerated_docstrings_example.rb +0 -19
  105. data/failing_examples/failure_in_setup.rb +0 -10
  106. data/failing_examples/failure_in_teardown.rb +0 -10
  107. data/failing_examples/mocking_example.rb +0 -40
  108. data/failing_examples/mocking_with_flexmock.rb +0 -26
  109. data/failing_examples/mocking_with_mocha.rb +0 -25
  110. data/failing_examples/mocking_with_rr.rb +0 -27
  111. data/failing_examples/partial_mock_example.rb +0 -20
  112. data/failing_examples/predicate_example.rb +0 -29
  113. data/failing_examples/raising_example.rb +0 -47
  114. data/failing_examples/spec_helper.rb +0 -3
  115. data/failing_examples/syntax_error_example.rb +0 -7
  116. data/failing_examples/team_spec.rb +0 -44
  117. data/failing_examples/timeout_behaviour.rb +0 -7
  118. data/lib/spec/extensions/main.rb +0 -87
  119. data/lib/spec/extensions/object.rb +0 -6
  120. data/spec/spec/extensions/main_spec.rb +0 -71
@@ -2,39 +2,54 @@ module Spec
2
2
  module Matchers
3
3
 
4
4
  class ThrowSymbol #:nodoc:
5
- def initialize(expected=nil)
6
- @expected = expected
7
- @actual = nil
5
+ def initialize(expected_symbol = nil, expected_arg=nil)
6
+ @expected_symbol = expected_symbol
7
+ @expected_arg = expected_arg
8
+ @caught_symbol = nil
8
9
  end
9
10
 
10
11
  def matches?(given_proc)
11
12
  begin
12
- given_proc.call
13
+ if @expected_symbol.nil?
14
+ given_proc.call
15
+ else
16
+ @caught_arg = catch :proc_did_not_throw_anything do
17
+ catch @expected_symbol do
18
+ given_proc.call
19
+ throw :proc_did_not_throw_anything, :nothing_thrown
20
+ end
21
+ end
22
+ @caught_symbol = @expected_symbol unless @caught_arg == :nothing_thrown
23
+ end
13
24
  rescue NameError => e
14
25
  raise e unless e.message =~ /uncaught throw/
15
- @actual = e.name.to_sym
26
+ @caught_symbol = e.name.to_sym
16
27
  ensure
17
- if @expected.nil?
18
- return @actual.nil? ? false : true
28
+ if @expected_symbol.nil?
29
+ return !@caught_symbol.nil?
19
30
  else
20
- return @actual == @expected
31
+ if @expected_arg.nil?
32
+ return @caught_symbol == @expected_symbol
33
+ else
34
+ return @caught_symbol == @expected_symbol && @caught_arg == @expected_arg
35
+ end
21
36
  end
22
37
  end
23
38
  end
24
39
 
25
40
  def failure_message
26
- if @actual
27
- "expected #{expected}, got #{@actual.inspect}"
41
+ if @caught_symbol
42
+ "expected #{expected}, got #{@caught_symbol.inspect}"
28
43
  else
29
44
  "expected #{expected} but nothing was thrown"
30
45
  end
31
46
  end
32
47
 
33
48
  def negative_failure_message
34
- if @expected
49
+ if @expected_symbol
35
50
  "expected #{expected} not to be thrown"
36
51
  else
37
- "expected no Symbol, got :#{@actual}"
52
+ "expected no Symbol, got :#{@caught_symbol}"
38
53
  end
39
54
  end
40
55
 
@@ -45,7 +60,11 @@ module Spec
45
60
  private
46
61
 
47
62
  def expected
48
- @expected.nil? ? "a Symbol" : @expected.inspect
63
+ @expected_symbol.nil? ? "a Symbol" : "#{@expected_symbol.inspect}#{args}"
64
+ end
65
+
66
+ def args
67
+ @expected_arg.nil? ? "" : " with #{@expected_arg.inspect}"
49
68
  end
50
69
 
51
70
  end
@@ -53,20 +72,27 @@ module Spec
53
72
  # :call-seq:
54
73
  # should throw_symbol()
55
74
  # should throw_symbol(:sym)
75
+ # should throw_symbol(:sym, arg)
56
76
  # should_not throw_symbol()
57
77
  # should_not throw_symbol(:sym)
58
- #
59
- # Given a Symbol argument, matches if the given proc throws the specified Symbol.
78
+ # should_not throw_symbol(:sym, arg)
60
79
  #
61
80
  # Given no argument, matches if a proc throws any Symbol.
62
81
  #
82
+ # Given a Symbol, matches if the given proc throws the specified Symbol.
83
+ #
84
+ # Given a Symbol and an arg, matches if the given proc throws the
85
+ # specified Symbol with the specified arg.
86
+ #
63
87
  # == Examples
64
88
  #
65
89
  # lambda { do_something_risky }.should throw_symbol
66
90
  # lambda { do_something_risky }.should throw_symbol(:that_was_risky)
91
+ # lambda { do_something_risky }.should throw_symbol(:that_was_risky, culprit)
67
92
  #
68
93
  # lambda { do_something_risky }.should_not throw_symbol
69
94
  # lambda { do_something_risky }.should_not throw_symbol(:that_was_risky)
95
+ # lambda { do_something_risky }.should_not throw_symbol(:that_was_risky, culprit)
70
96
  def throw_symbol(sym=nil)
71
97
  Matchers::ThrowSymbol.new(sym)
72
98
  end
data/lib/spec/matchers.rb CHANGED
@@ -1,3 +1,6 @@
1
+ require 'spec/matchers/generated_descriptions'
2
+ require 'spec/matchers/errors'
3
+ require 'spec/matchers/method_missing'
1
4
  require 'spec/matchers/simple_matcher'
2
5
  require 'spec/matchers/be'
3
6
  require 'spec/matchers/be_close'
@@ -132,31 +135,5 @@ module Spec
132
135
  # config.include(CustomGameMatchers)
133
136
  # end
134
137
  #
135
- module Matchers
136
- module ModuleMethods
137
- attr_accessor :last_matcher, :last_should
138
-
139
- def clear_generated_description
140
- self.last_matcher = nil
141
- self.last_should = nil
142
- end
143
-
144
- def generated_description
145
- last_should.nil? ? nil :
146
- "#{last_should} #{last_matcher.respond_to?(:description) ? last_matcher.description : 'NO NAME'}"
147
- end
148
- end
149
-
150
- extend ModuleMethods
151
-
152
- def method_missing(sym, *args, &block) # :nodoc:
153
- return Matchers::Be.new(sym, *args) if sym.starts_with?("be_")
154
- return Matchers::Has.new(sym, *args) if sym.starts_with?("have_")
155
- super
156
- end
157
-
158
- class MatcherError < StandardError
159
- end
160
-
161
- end
138
+ module Matchers; end
162
139
  end
@@ -22,7 +22,7 @@ module Spec
22
22
  end
23
23
 
24
24
  def example_pending(example, message, pending_caller)
25
- @pending_examples << [example.__full_description, message, pending_caller]
25
+ @pending_examples << [example.full_description, message, pending_caller]
26
26
  end
27
27
 
28
28
  def dump_failure(counter, failure)
@@ -34,8 +34,8 @@ module Spec
34
34
  "an example name directly, causing RSpec to run just the example",
35
35
  "matching that name"],
36
36
  :specification => ["-s", "--specification [NAME]", "DEPRECATED - use -e instead", "(This will be removed when autotest works with -e)"],
37
- :line => ["-l", "--line LINE_NUMBER", Integer, "Execute behaviour or specification at given line.",
38
- "(does not work for dynamically generated specs)"],
37
+ :line => ["-l", "--line LINE_NUMBER", Integer, "Execute example group or example at given line.",
38
+ "(does not work for dynamically generated examples)"],
39
39
  :format => ["-f", "--format FORMAT[:WHERE]","Specifies what format to use for output. Specify WHERE to tell",
40
40
  "the formatter where to write the output. All built-in formats",
41
41
  "expect WHERE to be a file name, and will write to $stdout if it's",
@@ -159,7 +159,7 @@ module Spec
159
159
 
160
160
  protected
161
161
  def example_name
162
- @example.__full_description
162
+ @example.full_description
163
163
  end
164
164
  end
165
165
  end
data/lib/spec/runner.rb CHANGED
@@ -187,7 +187,7 @@ module Spec
187
187
  def register_at_exit_hook # :nodoc:
188
188
  unless @already_registered_at_exit_hook
189
189
  at_exit do
190
- unless $! || Spec.run? || Spec::Example::ExampleGroupFactory.all_registered?(options.example_groups)
190
+ unless $! || Spec.run? || Spec::Example::ExampleGroupFactory.registered_or_ancestor_of_registered?(options.example_groups)
191
191
  success = Spec.run
192
192
  exit success if Spec.exit?
193
193
  end
data/lib/spec/version.rb CHANGED
@@ -3,7 +3,7 @@ module Spec
3
3
  unless defined? MAJOR
4
4
  MAJOR = 1
5
5
  MINOR = 1
6
- TINY = 10
6
+ TINY = 11
7
7
 
8
8
  STRING = [MAJOR, MINOR, TINY].join('.')
9
9
 
data/lib/spec.rb CHANGED
@@ -5,6 +5,7 @@ require 'spec/extensions'
5
5
  require 'spec/runner'
6
6
  require 'spec/adapters'
7
7
  require 'spec/version'
8
+ require 'spec/dsl'
8
9
 
9
10
  if Object.const_defined?(:Test)
10
11
  require 'spec/interop/test'
data/rspec.gemspec CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = %q{rspec}
5
- s.version = "1.1.10"
5
+ s.version = "1.1.11"
6
6
 
7
7
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
8
8
  s.authors = ["RSpec Development Team"]
@@ -10,33 +10,13 @@ Gem::Specification.new do |s|
10
10
  s.description = %q{Behaviour Driven Development for Ruby.}
11
11
  s.email = ["rspec-devel@rubyforge.org"]
12
12
  s.executables = ["autospec", "spec"]
13
- s.extra_rdoc_files = ["History.txt", "License.txt", "Manifest.txt", "README.txt", "TODO.txt", "examples/pure/priority.txt", "examples/stories/game-of-life/README.txt", "examples/stories/game-of-life/behaviour/stories/stories.txt", "failing_examples/README.txt", "spec/spec/runner/empty_file.txt", "spec/spec/runner/examples.txt", "spec/spec/runner/failed.txt"]
14
- s.files = ["History.txt", "License.txt", "Manifest.txt", "README.txt", "Rakefile", "TODO.txt", "bin/autospec", "bin/spec", "examples/pure/autogenerated_docstrings_example.rb", "examples/pure/before_and_after_example.rb", "examples/pure/behave_as_example.rb", "examples/pure/custom_expectation_matchers.rb", "examples/pure/custom_formatter.rb", "examples/pure/dynamic_spec.rb", "examples/pure/file_accessor.rb", "examples/pure/file_accessor_spec.rb", "examples/pure/greeter_spec.rb", "examples/pure/helper_method_example.rb", "examples/pure/io_processor.rb", "examples/pure/io_processor_spec.rb", "examples/pure/legacy_spec.rb", "examples/pure/mocking_example.rb", "examples/pure/multi_threaded_behaviour_runner.rb", "examples/pure/nested_classes_example.rb", "examples/pure/partial_mock_example.rb", "examples/pure/pending_example.rb", "examples/pure/predicate_example.rb", "examples/pure/priority.txt", "examples/pure/shared_example_group_example.rb", "examples/pure/shared_stack_examples.rb", "examples/pure/spec_helper.rb", "examples/pure/stack.rb", "examples/pure/stack_spec.rb", "examples/pure/stack_spec_with_nested_example_groups.rb", "examples/pure/stubbing_example.rb", "examples/pure/yielding_example.rb", "examples/stories/adder.rb", "examples/stories/addition", "examples/stories/addition.rb", "examples/stories/calculator.rb", "examples/stories/game-of-life/.loadpath", "examples/stories/game-of-life/README.txt", "examples/stories/game-of-life/behaviour/everything.rb", "examples/stories/game-of-life/behaviour/examples/examples.rb", "examples/stories/game-of-life/behaviour/examples/game_behaviour.rb", "examples/stories/game-of-life/behaviour/examples/grid_behaviour.rb", "examples/stories/game-of-life/behaviour/stories/CellsWithLessThanTwoNeighboursDie.story", "examples/stories/game-of-life/behaviour/stories/CellsWithMoreThanThreeNeighboursDie.story", "examples/stories/game-of-life/behaviour/stories/EmptySpacesWithThreeNeighboursCreateACell.story", "examples/stories/game-of-life/behaviour/stories/ICanCreateACell.story", "examples/stories/game-of-life/behaviour/stories/ICanKillACell.story", "examples/stories/game-of-life/behaviour/stories/TheGridWraps.story", "examples/stories/game-of-life/behaviour/stories/create_a_cell.rb", "examples/stories/game-of-life/behaviour/stories/helper.rb", "examples/stories/game-of-life/behaviour/stories/kill_a_cell.rb", "examples/stories/game-of-life/behaviour/stories/steps.rb", "examples/stories/game-of-life/behaviour/stories/stories.rb", "examples/stories/game-of-life/behaviour/stories/stories.txt", "examples/stories/game-of-life/life.rb", "examples/stories/game-of-life/life/game.rb", "examples/stories/game-of-life/life/grid.rb", "examples/stories/helper.rb", "examples/stories/steps/addition_steps.rb", "failing_examples/README.txt", "failing_examples/diffing_spec.rb", "failing_examples/failing_autogenerated_docstrings_example.rb", "failing_examples/failure_in_setup.rb", "failing_examples/failure_in_teardown.rb", "failing_examples/mocking_example.rb", "failing_examples/mocking_with_flexmock.rb", "failing_examples/mocking_with_mocha.rb", "failing_examples/mocking_with_rr.rb", "failing_examples/partial_mock_example.rb", "failing_examples/predicate_example.rb", "failing_examples/raising_example.rb", "failing_examples/spec_helper.rb", "failing_examples/syntax_error_example.rb", "failing_examples/team_spec.rb", "failing_examples/timeout_behaviour.rb", "init.rb", "lib/autotest/discover.rb", "lib/autotest/rspec.rb", "lib/spec.rb", "lib/spec/adapters.rb", "lib/spec/adapters/ruby_engine.rb", "lib/spec/adapters/ruby_engine/mri.rb", "lib/spec/adapters/ruby_engine/rubinius.rb", "lib/spec/example.rb", "lib/spec/example/before_and_after_hooks.rb", "lib/spec/example/configuration.rb", "lib/spec/example/errors.rb", "lib/spec/example/example_group.rb", "lib/spec/example/example_group_factory.rb", "lib/spec/example/example_group_methods.rb", "lib/spec/example/example_matcher.rb", "lib/spec/example/example_methods.rb", "lib/spec/example/module_reopening_fix.rb", "lib/spec/example/pending.rb", "lib/spec/example/shared_example_group.rb", "lib/spec/expectations.rb", "lib/spec/expectations/differs/default.rb", "lib/spec/expectations/errors.rb", "lib/spec/expectations/extensions.rb", "lib/spec/expectations/extensions/object.rb", "lib/spec/expectations/extensions/string_and_symbol.rb", "lib/spec/expectations/handler.rb", "lib/spec/extensions.rb", "lib/spec/extensions/class.rb", "lib/spec/extensions/main.rb", "lib/spec/extensions/metaclass.rb", "lib/spec/extensions/object.rb", "lib/spec/interop/test.rb", "lib/spec/interop/test/unit/autorunner.rb", "lib/spec/interop/test/unit/testcase.rb", "lib/spec/interop/test/unit/testresult.rb", "lib/spec/interop/test/unit/testsuite_adapter.rb", "lib/spec/interop/test/unit/ui/console/testrunner.rb", "lib/spec/matchers.rb", "lib/spec/matchers/be.rb", "lib/spec/matchers/be_close.rb", "lib/spec/matchers/change.rb", "lib/spec/matchers/eql.rb", "lib/spec/matchers/equal.rb", "lib/spec/matchers/exist.rb", "lib/spec/matchers/has.rb", "lib/spec/matchers/have.rb", "lib/spec/matchers/include.rb", "lib/spec/matchers/match.rb", "lib/spec/matchers/operator_matcher.rb", "lib/spec/matchers/raise_error.rb", "lib/spec/matchers/respond_to.rb", "lib/spec/matchers/satisfy.rb", "lib/spec/matchers/simple_matcher.rb", "lib/spec/matchers/throw_symbol.rb", "lib/spec/mocks.rb", "lib/spec/mocks/argument_constraints.rb", "lib/spec/mocks/argument_expectation.rb", "lib/spec/mocks/error_generator.rb", "lib/spec/mocks/errors.rb", "lib/spec/mocks/extensions.rb", "lib/spec/mocks/extensions/object.rb", "lib/spec/mocks/framework.rb", "lib/spec/mocks/message_expectation.rb", "lib/spec/mocks/methods.rb", "lib/spec/mocks/mock.rb", "lib/spec/mocks/order_group.rb", "lib/spec/mocks/proxy.rb", "lib/spec/mocks/space.rb", "lib/spec/mocks/spec_methods.rb", "lib/spec/rake/spectask.rb", "lib/spec/rake/verify_rcov.rb", "lib/spec/runner.rb", "lib/spec/runner/backtrace_tweaker.rb", "lib/spec/runner/class_and_arguments_parser.rb", "lib/spec/runner/command_line.rb", "lib/spec/runner/drb_command_line.rb", "lib/spec/runner/example_group_runner.rb", "lib/spec/runner/formatter/base_formatter.rb", "lib/spec/runner/formatter/base_text_formatter.rb", "lib/spec/runner/formatter/failing_example_groups_formatter.rb", "lib/spec/runner/formatter/failing_examples_formatter.rb", "lib/spec/runner/formatter/html_formatter.rb", "lib/spec/runner/formatter/nested_text_formatter.rb", "lib/spec/runner/formatter/profile_formatter.rb", "lib/spec/runner/formatter/progress_bar_formatter.rb", "lib/spec/runner/formatter/snippet_extractor.rb", "lib/spec/runner/formatter/specdoc_formatter.rb", "lib/spec/runner/formatter/story/html_formatter.rb", "lib/spec/runner/formatter/story/plain_text_formatter.rb", "lib/spec/runner/formatter/story/progress_bar_formatter.rb", "lib/spec/runner/formatter/text_mate_formatter.rb", "lib/spec/runner/heckle_runner.rb", "lib/spec/runner/heckle_runner_unsupported.rb", "lib/spec/runner/option_parser.rb", "lib/spec/runner/options.rb", "lib/spec/runner/reporter.rb", "lib/spec/runner/spec_parser.rb", "lib/spec/story.rb", "lib/spec/story/extensions.rb", "lib/spec/story/extensions/main.rb", "lib/spec/story/extensions/regexp.rb", "lib/spec/story/extensions/string.rb", "lib/spec/story/given_scenario.rb", "lib/spec/story/runner.rb", "lib/spec/story/runner/plain_text_story_runner.rb", "lib/spec/story/runner/scenario_collector.rb", "lib/spec/story/runner/scenario_runner.rb", "lib/spec/story/runner/story_mediator.rb", "lib/spec/story/runner/story_parser.rb", "lib/spec/story/runner/story_runner.rb", "lib/spec/story/scenario.rb", "lib/spec/story/step.rb", "lib/spec/story/step_group.rb", "lib/spec/story/step_mother.rb", "lib/spec/story/story.rb", "lib/spec/story/world.rb", "lib/spec/version.rb", "plugins/mock_frameworks/flexmock.rb", "plugins/mock_frameworks/mocha.rb", "plugins/mock_frameworks/rr.rb", "plugins/mock_frameworks/rspec.rb", "rake_tasks/examples.rake", "rake_tasks/examples_with_rcov.rake", "rake_tasks/failing_examples_with_html.rake", "rake_tasks/verify_rcov.rake", "rspec.gemspec", "spec/README.jruby", "spec/autotest/autotest_helper.rb", "spec/autotest/autotest_matchers.rb", "spec/autotest/discover_spec.rb", "spec/autotest/rspec_spec.rb", "spec/rspec_suite.rb", "spec/ruby_forker.rb", "spec/spec.opts", "spec/spec/adapters/ruby_engine_spec.rb", "spec/spec/example/configuration_spec.rb", "spec/spec/example/example_group_class_definition_spec.rb", "spec/spec/example/example_group_factory_spec.rb", "spec/spec/example/example_group_methods_spec.rb", "spec/spec/example/example_group_spec.rb", "spec/spec/example/example_matcher_spec.rb", "spec/spec/example/example_methods_spec.rb", "spec/spec/example/example_runner_spec.rb", "spec/spec/example/nested_example_group_spec.rb", "spec/spec/example/pending_module_spec.rb", "spec/spec/example/predicate_matcher_spec.rb", "spec/spec/example/shared_example_group_spec.rb", "spec/spec/example/subclassing_example_group_spec.rb", "spec/spec/expectations/differs/default_spec.rb", "spec/spec/expectations/extensions/object_spec.rb", "spec/spec/expectations/fail_with_spec.rb", "spec/spec/extensions/main_spec.rb", "spec/spec/interop/test/unit/resources/spec_that_fails.rb", "spec/spec/interop/test/unit/resources/spec_that_passes.rb", "spec/spec/interop/test/unit/resources/spec_with_errors.rb", "spec/spec/interop/test/unit/resources/spec_with_options_hash.rb", "spec/spec/interop/test/unit/resources/test_case_that_fails.rb", "spec/spec/interop/test/unit/resources/test_case_that_passes.rb", "spec/spec/interop/test/unit/resources/test_case_with_errors.rb", "spec/spec/interop/test/unit/resources/testsuite_adapter_spec_with_test_unit.rb", "spec/spec/interop/test/unit/spec_spec.rb", "spec/spec/interop/test/unit/test_unit_spec_helper.rb", "spec/spec/interop/test/unit/testcase_spec.rb", "spec/spec/interop/test/unit/testsuite_adapter_spec.rb", "spec/spec/matchers/be_close_spec.rb", "spec/spec/matchers/be_spec.rb", "spec/spec/matchers/change_spec.rb", "spec/spec/matchers/description_generation_spec.rb", "spec/spec/matchers/eql_spec.rb", "spec/spec/matchers/equal_spec.rb", "spec/spec/matchers/exist_spec.rb", "spec/spec/matchers/handler_spec.rb", "spec/spec/matchers/has_spec.rb", "spec/spec/matchers/have_spec.rb", "spec/spec/matchers/include_spec.rb", "spec/spec/matchers/match_spec.rb", "spec/spec/matchers/matcher_methods_spec.rb", "spec/spec/matchers/mock_constraint_matchers_spec.rb", "spec/spec/matchers/operator_matcher_spec.rb", "spec/spec/matchers/raise_error_spec.rb", "spec/spec/matchers/respond_to_spec.rb", "spec/spec/matchers/satisfy_spec.rb", "spec/spec/matchers/simple_matcher_spec.rb", "spec/spec/matchers/throw_symbol_spec.rb", "spec/spec/mocks/any_number_of_times_spec.rb", "spec/spec/mocks/argument_expectation_spec.rb", "spec/spec/mocks/at_least_spec.rb", "spec/spec/mocks/at_most_spec.rb", "spec/spec/mocks/bug_report_10260_spec.rb", "spec/spec/mocks/bug_report_10263_spec.rb", "spec/spec/mocks/bug_report_11545_spec.rb", "spec/spec/mocks/bug_report_15719_spec.rb", "spec/spec/mocks/bug_report_496.rb", "spec/spec/mocks/bug_report_7611_spec.rb", "spec/spec/mocks/bug_report_7805_spec.rb", "spec/spec/mocks/bug_report_8165_spec.rb", "spec/spec/mocks/bug_report_8302_spec.rb", "spec/spec/mocks/failing_mock_argument_constraints_spec.rb", "spec/spec/mocks/hash_including_matcher_spec.rb", "spec/spec/mocks/mock_ordering_spec.rb", "spec/spec/mocks/mock_space_spec.rb", "spec/spec/mocks/mock_spec.rb", "spec/spec/mocks/multiple_return_value_spec.rb", "spec/spec/mocks/nil_expectation_warning_spec.rb", "spec/spec/mocks/null_object_mock_spec.rb", "spec/spec/mocks/once_counts_spec.rb", "spec/spec/mocks/options_hash_spec.rb", "spec/spec/mocks/partial_mock_spec.rb", "spec/spec/mocks/partial_mock_using_mocks_directly_spec.rb", "spec/spec/mocks/passing_mock_argument_constraints_spec.rb", "spec/spec/mocks/precise_counts_spec.rb", "spec/spec/mocks/record_messages_spec.rb", "spec/spec/mocks/stub_spec.rb", "spec/spec/mocks/twice_counts_spec.rb", "spec/spec/package/bin_spec_spec.rb", "spec/spec/runner/class_and_argument_parser_spec.rb", "spec/spec/runner/command_line_spec.rb", "spec/spec/runner/drb_command_line_spec.rb", "spec/spec/runner/empty_file.txt", "spec/spec/runner/examples.txt", "spec/spec/runner/failed.txt", "spec/spec/runner/formatter/base_formatter_spec.rb", "spec/spec/runner/formatter/failing_example_groups_formatter_spec.rb", "spec/spec/runner/formatter/failing_examples_formatter_spec.rb", "spec/spec/runner/formatter/html_formatted-1.8.4.html", "spec/spec/runner/formatter/html_formatted-1.8.5-jruby.html", "spec/spec/runner/formatter/html_formatted-1.8.5.html", "spec/spec/runner/formatter/html_formatted-1.8.6-jruby.html", "spec/spec/runner/formatter/html_formatted-1.8.6.html", "spec/spec/runner/formatter/html_formatter_spec.rb", "spec/spec/runner/formatter/nested_text_formatter_spec.rb", "spec/spec/runner/formatter/profile_formatter_spec.rb", "spec/spec/runner/formatter/progress_bar_formatter_spec.rb", "spec/spec/runner/formatter/snippet_extractor_spec.rb", "spec/spec/runner/formatter/spec_mate_formatter_spec.rb", "spec/spec/runner/formatter/specdoc_formatter_spec.rb", "spec/spec/runner/formatter/story/html_formatter_spec.rb", "spec/spec/runner/formatter/story/plain_text_formatter_spec.rb", "spec/spec/runner/formatter/story/progress_bar_formatter_spec.rb", "spec/spec/runner/formatter/text_mate_formatted-1.8.4.html", "spec/spec/runner/formatter/text_mate_formatted-1.8.6.html", "spec/spec/runner/heckle_runner_spec.rb", "spec/spec/runner/heckler_spec.rb", "spec/spec/runner/noisy_backtrace_tweaker_spec.rb", "spec/spec/runner/option_parser_spec.rb", "spec/spec/runner/options_spec.rb", "spec/spec/runner/output_one_time_fixture.rb", "spec/spec/runner/output_one_time_fixture_runner.rb", "spec/spec/runner/output_one_time_spec.rb", "spec/spec/runner/quiet_backtrace_tweaker_spec.rb", "spec/spec/runner/reporter_spec.rb", "spec/spec/runner/resources/a_bar.rb", "spec/spec/runner/resources/a_foo.rb", "spec/spec/runner/resources/a_spec.rb", "spec/spec/runner/spec.opts", "spec/spec/runner/spec_drb.opts", "spec/spec/runner/spec_parser/spec_parser_fixture.rb", "spec/spec/runner/spec_parser_spec.rb", "spec/spec/runner/spec_spaced.opts", "spec/spec/runner_spec.rb", "spec/spec/spec_classes.rb", "spec/spec/story/builders.rb", "spec/spec/story/extensions/main_spec.rb", "spec/spec/story/extensions_spec.rb", "spec/spec/story/given_scenario_spec.rb", "spec/spec/story/runner/plain_text_story_runner_spec.rb", "spec/spec/story/runner/scenario_collector_spec.rb", "spec/spec/story/runner/scenario_runner_spec.rb", "spec/spec/story/runner/story_mediator_spec.rb", "spec/spec/story/runner/story_parser_spec.rb", "spec/spec/story/runner/story_runner_spec.rb", "spec/spec/story/runner_spec.rb", "spec/spec/story/scenario_spec.rb", "spec/spec/story/step_group_spec.rb", "spec/spec/story/step_mother_spec.rb", "spec/spec/story/step_spec.rb", "spec/spec/story/story_helper.rb", "spec/spec/story/story_spec.rb", "spec/spec/story/world_spec.rb", "spec/spec_helper.rb", "stories/all.rb", "stories/configuration/before_blocks.story", "stories/configuration/stories.rb", "stories/example_groups/autogenerated_docstrings", "stories/example_groups/example_group_with_should_methods", "stories/example_groups/nested_groups", "stories/example_groups/output", "stories/example_groups/stories.rb", "stories/helper.rb", "stories/interop/examples_and_tests_together", "stories/interop/stories.rb", "stories/interop/test_case_with_should_methods", "stories/mock_framework_integration/stories.rb", "stories/mock_framework_integration/use_flexmock.story", "stories/pending_stories/README", "stories/resources/helpers/cmdline.rb", "stories/resources/helpers/story_helper.rb", "stories/resources/matchers/smart_match.rb", "stories/resources/spec/before_blocks_example.rb", "stories/resources/spec/example_group_with_should_methods.rb", "stories/resources/spec/simple_spec.rb", "stories/resources/spec/spec_with_flexmock.rb", "stories/resources/steps/running_rspec.rb", "stories/resources/stories/failing_story.rb", "stories/resources/test/spec_and_test_together.rb", "stories/resources/test/test_case_with_should_methods.rb", "stories/stories/multiline_steps.story", "stories/stories/steps/multiline_steps.rb", "stories/stories/stories.rb", "story_server/prototype/javascripts/builder.js", "story_server/prototype/javascripts/controls.js", "story_server/prototype/javascripts/dragdrop.js", "story_server/prototype/javascripts/effects.js", "story_server/prototype/javascripts/prototype.js", "story_server/prototype/javascripts/rspec.js", "story_server/prototype/javascripts/scriptaculous.js", "story_server/prototype/javascripts/slider.js", "story_server/prototype/javascripts/sound.js", "story_server/prototype/javascripts/unittest.js", "story_server/prototype/lib/server.rb", "story_server/prototype/stories.html", "story_server/prototype/stylesheets/rspec.css", "story_server/prototype/stylesheets/test.css"]
13
+ s.extra_rdoc_files = ["History.txt", "License.txt", "Manifest.txt", "README.txt", "TODO.txt", "examples/passing/priority.txt", "examples/stories/game-of-life/README.txt", "examples/stories/game-of-life/behaviour/stories/stories.txt", "failing_examples/README.txt", "spec/spec/runner/empty_file.txt", "spec/spec/runner/examples.txt", "spec/spec/runner/failed.txt"]
14
+ s.files = ["History.txt", "License.txt", "Manifest.txt", "README.txt", "Rakefile", "TODO.txt", "bin/autospec", "bin/spec", "examples/passing/autogenerated_docstrings_example.rb", "examples/passing/before_and_after_example.rb", "examples/passing/behave_as_example.rb", "examples/passing/custom_expectation_matchers.rb", "examples/passing/custom_formatter.rb", "examples/passing/dynamic_spec.rb", "examples/passing/file_accessor.rb", "examples/passing/file_accessor_spec.rb", "examples/passing/greeter_spec.rb", "examples/passing/helper_method_example.rb", "examples/passing/io_processor.rb", "examples/passing/io_processor_spec.rb", "examples/passing/legacy_spec.rb", "examples/passing/mocking_example.rb", "examples/passing/multi_threaded_behaviour_runner.rb", "examples/passing/nested_classes_example.rb", "examples/passing/partial_mock_example.rb", "examples/passing/pending_example.rb", "examples/passing/predicate_example.rb", "examples/passing/priority.txt", "examples/passing/shared_example_group_example.rb", "examples/passing/shared_stack_examples.rb", "examples/passing/spec_helper.rb", "examples/passing/stack.rb", "examples/passing/stack_spec.rb", "examples/passing/stack_spec_with_nested_example_groups.rb", "examples/passing/stubbing_example.rb", "examples/passing/yielding_example.rb", "examples/stories/adder.rb", "examples/stories/addition", "examples/stories/addition.rb", "examples/stories/calculator.rb", "examples/stories/game-of-life/.loadpath", "examples/stories/game-of-life/README.txt", "examples/stories/game-of-life/behaviour/everything.rb", "examples/stories/game-of-life/behaviour/examples/examples.rb", "examples/stories/game-of-life/behaviour/examples/game_behaviour.rb", "examples/stories/game-of-life/behaviour/examples/grid_behaviour.rb", "examples/stories/game-of-life/behaviour/stories/CellsWithLessThanTwoNeighboursDie.story", "examples/stories/game-of-life/behaviour/stories/CellsWithMoreThanThreeNeighboursDie.story", "examples/stories/game-of-life/behaviour/stories/EmptySpacesWithThreeNeighboursCreateACell.story", "examples/stories/game-of-life/behaviour/stories/ICanCreateACell.story", "examples/stories/game-of-life/behaviour/stories/ICanKillACell.story", "examples/stories/game-of-life/behaviour/stories/TheGridWraps.story", "examples/stories/game-of-life/behaviour/stories/create_a_cell.rb", "examples/stories/game-of-life/behaviour/stories/helper.rb", "examples/stories/game-of-life/behaviour/stories/kill_a_cell.rb", "examples/stories/game-of-life/behaviour/stories/steps.rb", "examples/stories/game-of-life/behaviour/stories/stories.rb", "examples/stories/game-of-life/behaviour/stories/stories.txt", "examples/stories/game-of-life/life.rb", "examples/stories/game-of-life/life/game.rb", "examples/stories/game-of-life/life/grid.rb", "examples/stories/helper.rb", "examples/stories/steps/addition_steps.rb", "failing_examples/README.txt", "failing_examples/diffing_spec.rb", "failing_examples/failing_autogenerated_docstrings_example.rb", "failing_examples/failure_in_setup.rb", "failing_examples/failure_in_teardown.rb", "failing_examples/mocking_example.rb", "failing_examples/mocking_with_flexmock.rb", "failing_examples/mocking_with_mocha.rb", "failing_examples/mocking_with_rr.rb", "failing_examples/partial_mock_example.rb", "failing_examples/predicate_example.rb", "failing_examples/raising_example.rb", "failing_examples/spec_helper.rb", "failing_examples/syntax_error_example.rb", "failing_examples/team_spec.rb", "failing_examples/timeout_behaviour.rb", "init.rb", "lib/autotest/discover.rb", "lib/autotest/rspec.rb", "lib/spec.rb", "lib/spec/adapters.rb", "lib/spec/adapters/ruby_engine.rb", "lib/spec/adapters/ruby_engine/mri.rb", "lib/spec/adapters/ruby_engine/rubinius.rb", "lib/spec/example.rb", "lib/spec/example/before_and_after_hooks.rb", "lib/spec/example/configuration.rb", "lib/spec/example/errors.rb", "lib/spec/example/example_group.rb", "lib/spec/example/example_group_factory.rb", "lib/spec/example/example_group_methods.rb", "lib/spec/example/example_matcher.rb", "lib/spec/example/example_methods.rb", "lib/spec/example/module_reopening_fix.rb", "lib/spec/example/pending.rb", "lib/spec/example/shared_example_group.rb", "lib/spec/expectations.rb", "lib/spec/expectations/differs/default.rb", "lib/spec/expectations/errors.rb", "lib/spec/expectations/extensions.rb", "lib/spec/expectations/extensions/object.rb", "lib/spec/expectations/extensions/string_and_symbol.rb", "lib/spec/expectations/handler.rb", "lib/spec/extensions.rb", "lib/spec/extensions/class.rb", "lib/spec/extensions/main.rb", "lib/spec/extensions/metaclass.rb", "lib/spec/extensions/object.rb", "lib/spec/interop/test.rb", "lib/spec/interop/test/unit/autorunner.rb", "lib/spec/interop/test/unit/testcase.rb", "lib/spec/interop/test/unit/testresult.rb", "lib/spec/interop/test/unit/testsuite_adapter.rb", "lib/spec/interop/test/unit/ui/console/testrunner.rb", "lib/spec/matchers.rb", "lib/spec/matchers/be.rb", "lib/spec/matchers/be_close.rb", "lib/spec/matchers/change.rb", "lib/spec/matchers/eql.rb", "lib/spec/matchers/equal.rb", "lib/spec/matchers/exist.rb", "lib/spec/matchers/has.rb", "lib/spec/matchers/have.rb", "lib/spec/matchers/include.rb", "lib/spec/matchers/match.rb", "lib/spec/matchers/operator_matcher.rb", "lib/spec/matchers/raise_error.rb", "lib/spec/matchers/respond_to.rb", "lib/spec/matchers/satisfy.rb", "lib/spec/matchers/simple_matcher.rb", "lib/spec/matchers/throw_symbol.rb", "lib/spec/mocks.rb", "lib/spec/mocks/argument_constraints.rb", "lib/spec/mocks/argument_expectation.rb", "lib/spec/mocks/error_generator.rb", "lib/spec/mocks/errors.rb", "lib/spec/mocks/extensions.rb", "lib/spec/mocks/extensions/object.rb", "lib/spec/mocks/framework.rb", "lib/spec/mocks/message_expectation.rb", "lib/spec/mocks/methods.rb", "lib/spec/mocks/mock.rb", "lib/spec/mocks/order_group.rb", "lib/spec/mocks/proxy.rb", "lib/spec/mocks/space.rb", "lib/spec/mocks/spec_methods.rb", "lib/spec/rake/spectask.rb", "lib/spec/rake/verify_rcov.rb", "lib/spec/runner.rb", "lib/spec/runner/backtrace_tweaker.rb", "lib/spec/runner/class_and_arguments_parser.rb", "lib/spec/runner/command_line.rb", "lib/spec/runner/drb_command_line.rb", "lib/spec/runner/example_group_runner.rb", "lib/spec/runner/formatter/base_formatter.rb", "lib/spec/runner/formatter/base_text_formatter.rb", "lib/spec/runner/formatter/failing_example_groups_formatter.rb", "lib/spec/runner/formatter/failing_examples_formatter.rb", "lib/spec/runner/formatter/html_formatter.rb", "lib/spec/runner/formatter/nested_text_formatter.rb", "lib/spec/runner/formatter/profile_formatter.rb", "lib/spec/runner/formatter/progress_bar_formatter.rb", "lib/spec/runner/formatter/snippet_extractor.rb", "lib/spec/runner/formatter/specdoc_formatter.rb", "lib/spec/runner/formatter/story/html_formatter.rb", "lib/spec/runner/formatter/story/plain_text_formatter.rb", "lib/spec/runner/formatter/story/progress_bar_formatter.rb", "lib/spec/runner/formatter/text_mate_formatter.rb", "lib/spec/runner/heckle_runner.rb", "lib/spec/runner/heckle_runner_unsupported.rb", "lib/spec/runner/option_parser.rb", "lib/spec/runner/options.rb", "lib/spec/runner/reporter.rb", "lib/spec/runner/spec_parser.rb", "lib/spec/story.rb", "lib/spec/story/extensions.rb", "lib/spec/story/extensions/main.rb", "lib/spec/story/extensions/regexp.rb", "lib/spec/story/extensions/string.rb", "lib/spec/story/given_scenario.rb", "lib/spec/story/runner.rb", "lib/spec/story/runner/plain_text_story_runner.rb", "lib/spec/story/runner/scenario_collector.rb", "lib/spec/story/runner/scenario_runner.rb", "lib/spec/story/runner/story_mediator.rb", "lib/spec/story/runner/story_parser.rb", "lib/spec/story/runner/story_runner.rb", "lib/spec/story/scenario.rb", "lib/spec/story/step.rb", "lib/spec/story/step_group.rb", "lib/spec/story/step_mother.rb", "lib/spec/story/story.rb", "lib/spec/story/world.rb", "lib/spec/version.rb", "plugins/mock_frameworks/flexmock.rb", "plugins/mock_frameworks/mocha.rb", "plugins/mock_frameworks/rr.rb", "plugins/mock_frameworks/rspec.rb", "rake_tasks/examples.rake", "rake_tasks/examples_with_rcov.rake", "rake_tasks/failing_examples_with_html.rake", "rake_tasks/verify_rcov.rake", "rspec.gemspec", "spec/README.jruby", "spec/autotest/autotest_helper.rb", "spec/autotest/autotest_matchers.rb", "spec/autotest/discover_spec.rb", "spec/autotest/rspec_spec.rb", "spec/rspec_suite.rb", "spec/ruby_forker.rb", "spec/spec.opts", "spec/spec/adapters/ruby_engine_spec.rb", "spec/spec/example/configuration_spec.rb", "spec/spec/example/example_group_class_definition_spec.rb", "spec/spec/example/example_group_factory_spec.rb", "spec/spec/example/example_group_methods_spec.rb", "spec/spec/example/example_group_spec.rb", "spec/spec/example/example_matcher_spec.rb", "spec/spec/example/example_methods_spec.rb", "spec/spec/example/example_runner_spec.rb", "spec/spec/example/nested_example_group_spec.rb", "spec/spec/example/pending_module_spec.rb", "spec/spec/example/predicate_matcher_spec.rb", "spec/spec/example/shared_example_group_spec.rb", "spec/spec/example/subclassing_example_group_spec.rb", "spec/spec/expectations/differs/default_spec.rb", "spec/spec/expectations/extensions/object_spec.rb", "spec/spec/expectations/fail_with_spec.rb", "spec/spec/extensions/main_spec.rb", "spec/spec/interop/test/unit/resources/spec_that_fails.rb", "spec/spec/interop/test/unit/resources/spec_that_passes.rb", "spec/spec/interop/test/unit/resources/spec_with_errors.rb", "spec/spec/interop/test/unit/resources/spec_with_options_hash.rb", "spec/spec/interop/test/unit/resources/test_case_that_fails.rb", "spec/spec/interop/test/unit/resources/test_case_that_passes.rb", "spec/spec/interop/test/unit/resources/test_case_with_errors.rb", "spec/spec/interop/test/unit/resources/testsuite_adapter_spec_with_test_unit.rb", "spec/spec/interop/test/unit/spec_spec.rb", "spec/spec/interop/test/unit/test_unit_spec_helper.rb", "spec/spec/interop/test/unit/testcase_spec.rb", "spec/spec/interop/test/unit/testsuite_adapter_spec.rb", "spec/spec/matchers/be_close_spec.rb", "spec/spec/matchers/be_spec.rb", "spec/spec/matchers/change_spec.rb", "spec/spec/matchers/description_generation_spec.rb", "spec/spec/matchers/eql_spec.rb", "spec/spec/matchers/equal_spec.rb", "spec/spec/matchers/exist_spec.rb", "spec/spec/matchers/handler_spec.rb", "spec/spec/matchers/has_spec.rb", "spec/spec/matchers/have_spec.rb", "spec/spec/matchers/include_spec.rb", "spec/spec/matchers/match_spec.rb", "spec/spec/matchers/matcher_methods_spec.rb", "spec/spec/matchers/mock_constraint_matchers_spec.rb", "spec/spec/matchers/operator_matcher_spec.rb", "spec/spec/matchers/raise_error_spec.rb", "spec/spec/matchers/respond_to_spec.rb", "spec/spec/matchers/satisfy_spec.rb", "spec/spec/matchers/simple_matcher_spec.rb", "spec/spec/matchers/throw_symbol_spec.rb", "spec/spec/mocks/any_number_of_times_spec.rb", "spec/spec/mocks/argument_expectation_spec.rb", "spec/spec/mocks/at_least_spec.rb", "spec/spec/mocks/at_most_spec.rb", "spec/spec/mocks/bug_report_10260_spec.rb", "spec/spec/mocks/bug_report_10263_spec.rb", "spec/spec/mocks/bug_report_11545_spec.rb", "spec/spec/mocks/bug_report_15719_spec.rb", "spec/spec/mocks/bug_report_496.rb", "spec/spec/mocks/bug_report_7611_spec.rb", "spec/spec/mocks/bug_report_7805_spec.rb", "spec/spec/mocks/bug_report_8165_spec.rb", "spec/spec/mocks/bug_report_8302_spec.rb", "spec/spec/mocks/failing_mock_argument_constraints_spec.rb", "spec/spec/mocks/hash_including_matcher_spec.rb", "spec/spec/mocks/mock_ordering_spec.rb", "spec/spec/mocks/mock_space_spec.rb", "spec/spec/mocks/mock_spec.rb", "spec/spec/mocks/multiple_return_value_spec.rb", "spec/spec/mocks/nil_expectation_warning_spec.rb", "spec/spec/mocks/null_object_mock_spec.rb", "spec/spec/mocks/once_counts_spec.rb", "spec/spec/mocks/options_hash_spec.rb", "spec/spec/mocks/partial_mock_spec.rb", "spec/spec/mocks/partial_mock_using_mocks_directly_spec.rb", "spec/spec/mocks/passing_mock_argument_constraints_spec.rb", "spec/spec/mocks/precise_counts_spec.rb", "spec/spec/mocks/record_messages_spec.rb", "spec/spec/mocks/stub_spec.rb", "spec/spec/mocks/twice_counts_spec.rb", "spec/spec/package/bin_spec_spec.rb", "spec/spec/runner/class_and_argument_parser_spec.rb", "spec/spec/runner/command_line_spec.rb", "spec/spec/runner/drb_command_line_spec.rb", "spec/spec/runner/empty_file.txt", "spec/spec/runner/examples.txt", "spec/spec/runner/failed.txt", "spec/spec/runner/formatter/base_formatter_spec.rb", "spec/spec/runner/formatter/failing_example_groups_formatter_spec.rb", "spec/spec/runner/formatter/failing_examples_formatter_spec.rb", "spec/spec/runner/formatter/html_formatted-1.8.4.html", "spec/spec/runner/formatter/html_formatted-1.8.5-jruby.html", "spec/spec/runner/formatter/html_formatted-1.8.5.html", "spec/spec/runner/formatter/html_formatted-1.8.6-jruby.html", "spec/spec/runner/formatter/html_formatted-1.8.6.html", "spec/spec/runner/formatter/html_formatter_spec.rb", "spec/spec/runner/formatter/nested_text_formatter_spec.rb", "spec/spec/runner/formatter/profile_formatter_spec.rb", "spec/spec/runner/formatter/progress_bar_formatter_spec.rb", "spec/spec/runner/formatter/snippet_extractor_spec.rb", "spec/spec/runner/formatter/spec_mate_formatter_spec.rb", "spec/spec/runner/formatter/specdoc_formatter_spec.rb", "spec/spec/runner/formatter/story/html_formatter_spec.rb", "spec/spec/runner/formatter/story/plain_text_formatter_spec.rb", "spec/spec/runner/formatter/story/progress_bar_formatter_spec.rb", "spec/spec/runner/formatter/text_mate_formatted-1.8.4.html", "spec/spec/runner/formatter/text_mate_formatted-1.8.6.html", "spec/spec/runner/heckle_runner_spec.rb", "spec/spec/runner/heckler_spec.rb", "spec/spec/runner/noisy_backtrace_tweaker_spec.rb", "spec/spec/runner/option_parser_spec.rb", "spec/spec/runner/options_spec.rb", "spec/spec/runner/output_one_time_fixture.rb", "spec/spec/runner/output_one_time_fixture_runner.rb", "spec/spec/runner/output_one_time_spec.rb", "spec/spec/runner/quiet_backtrace_tweaker_spec.rb", "spec/spec/runner/reporter_spec.rb", "spec/spec/runner/resources/a_bar.rb", "spec/spec/runner/resources/a_foo.rb", "spec/spec/runner/resources/a_spec.rb", "spec/spec/runner/spec.opts", "spec/spec/runner/spec_drb.opts", "spec/spec/runner/spec_parser/spec_parser_fixture.rb", "spec/spec/runner/spec_parser_spec.rb", "spec/spec/runner/spec_spaced.opts", "spec/spec/runner_spec.rb", "spec/spec/spec_classes.rb", "spec/spec/story/builders.rb", "spec/spec/story/extensions/main_spec.rb", "spec/spec/story/extensions_spec.rb", "spec/spec/story/given_scenario_spec.rb", "spec/spec/story/runner/plain_text_story_runner_spec.rb", "spec/spec/story/runner/scenario_collector_spec.rb", "spec/spec/story/runner/scenario_runner_spec.rb", "spec/spec/story/runner/story_mediator_spec.rb", "spec/spec/story/runner/story_parser_spec.rb", "spec/spec/story/runner/story_runner_spec.rb", "spec/spec/story/runner_spec.rb", "spec/spec/story/scenario_spec.rb", "spec/spec/story/step_group_spec.rb", "spec/spec/story/step_mother_spec.rb", "spec/spec/story/step_spec.rb", "spec/spec/story/story_helper.rb", "spec/spec/story/story_spec.rb", "spec/spec/story/world_spec.rb", "spec/spec_helper.rb", "stories/all.rb", "stories/configuration/before_blocks.story", "stories/configuration/stories.rb", "stories/example_groups/autogenerated_docstrings", "stories/example_groups/example_group_with_should_methods", "stories/example_groups/nested_groups", "stories/example_groups/output", "stories/example_groups/stories.rb", "stories/helper.rb", "stories/interop/examples_and_tests_together", "stories/interop/stories.rb", "stories/interop/test_case_with_should_methods", "stories/mock_framework_integration/stories.rb", "stories/mock_framework_integration/use_flexmock.story", "stories/pending_stories/README", "stories/resources/helpers/cmdline.rb", "stories/resources/helpers/story_helper.rb", "stories/resources/matchers/smart_match.rb", "stories/resources/spec/before_blocks_example.rb", "stories/resources/spec/example_group_with_should_methods.rb", "stories/resources/spec/simple_spec.rb", "stories/resources/spec/spec_with_flexmock.rb", "stories/resources/steps/running_rspec.rb", "stories/resources/stories/failing_story.rb", "stories/resources/test/spec_and_test_together.rb", "stories/resources/test/test_case_with_should_methods.rb", "stories/stories/multiline_steps.story", "stories/stories/steps/multiline_steps.rb", "stories/stories/stories.rb", "story_server/prototype/javascripts/builder.js", "story_server/prototype/javascripts/controls.js", "story_server/prototype/javascripts/dragdrop.js", "story_server/prototype/javascripts/effects.js", "story_server/prototype/javascripts/prototype.js", "story_server/prototype/javascripts/rspec.js", "story_server/prototype/javascripts/scriptaculous.js", "story_server/prototype/javascripts/slider.js", "story_server/prototype/javascripts/sound.js", "story_server/prototype/javascripts/unittest.js", "story_server/prototype/lib/server.rb", "story_server/prototype/stories.html", "story_server/prototype/stylesheets/rspec.css", "story_server/prototype/stylesheets/test.css"]
15
15
  s.has_rdoc = true
16
16
  s.homepage = %q{http://rspec.info/}
17
17
  s.rdoc_options = ["--main", "README.txt"]
18
18
  s.require_paths = ["lib"]
19
19
  s.rubyforge_project = %q{rspec}
20
20
  s.rubygems_version = %q{1.3.0}
21
- s.summary = %q{rspec 1.1.10}
22
-
23
- if s.respond_to? :specification_version then
24
- current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
25
- s.specification_version = 2
26
-
27
- if Gem::Version.new(Gem::RubyGemsVersion) >= Gem::Version.new('1.2.0') then
28
- s.add_development_dependency(%q<diff-lcs>, [">= 0"])
29
- s.add_development_dependency(%q<syntax>, [">= 0"])
30
- s.add_development_dependency(%q<spicycode-rcov>, [">= 0.8.1.3"])
31
- s.add_development_dependency(%q<hoe>, [">= 1.8.1"])
32
- else
33
- s.add_dependency(%q<diff-lcs>, [">= 0"])
34
- s.add_dependency(%q<syntax>, [">= 0"])
35
- s.add_dependency(%q<hoe>, [">= 1.8.1"])
36
- end
37
- else
38
- s.add_dependency(%q<diff-lcs>, [">= 0"])
39
- s.add_dependency(%q<syntax>, [">= 0"])
40
- s.add_dependency(%q<hoe>, [">= 1.8.1"])
41
- end
21
+ s.summary = %q{rspec 1.1.11}
42
22
  end
@@ -5,12 +5,12 @@ module Spec
5
5
  describe ExampleGroupFactory do
6
6
  describe "#get" do
7
7
  attr_reader :example_group
8
- before do
8
+ before(:each) do
9
9
  @example_group_class = Class.new(ExampleGroup)
10
10
  ExampleGroupFactory.register(:registered_type, @example_group_class)
11
11
  end
12
12
 
13
- after do
13
+ after(:each) do
14
14
  ExampleGroupFactory.reset
15
15
  end
16
16
 
@@ -57,6 +57,26 @@ module Spec
57
57
  example_group.superclass.should == Spec::Example::ExampleGroup
58
58
  end
59
59
 
60
+ it "should raise when no description is given" do
61
+ lambda {
62
+ Spec::Example::ExampleGroupFactory.create_example_group do; end
63
+ }.should raise_error(ArgumentError)
64
+ end
65
+
66
+ it "should raise when no block is given" do
67
+ lambda { Spec::Example::ExampleGroupFactory.create_example_group "foo" }.should raise_error(ArgumentError)
68
+ end
69
+
70
+ it "should run registered ExampleGroups" do
71
+ example_group = Spec::Example::ExampleGroupFactory.create_example_group "The ExampleGroup" do end
72
+ Spec::Runner.options.example_groups.should include(example_group)
73
+ end
74
+
75
+ it "should not run unregistered ExampleGroups" do
76
+ example_group = Spec::Example::ExampleGroupFactory.create_example_group "The ExampleGroup" do unregister; end
77
+ Spec::Runner.options.example_groups.should_not include(example_group)
78
+ end
79
+
60
80
  describe "with :type => :default" do
61
81
  it "should create a Spec::Example::ExampleGroup" do
62
82
  example_group = Spec::Example::ExampleGroupFactory.create_example_group(
@@ -102,7 +122,7 @@ module Spec
102
122
 
103
123
  it "should create and register a Spec::Example::SharedExampleGroup" do
104
124
  shared_example_group.should be_an_instance_of(Spec::Example::SharedExampleGroup)
105
- SharedExampleGroup.shared_example_groups.should include(shared_example_group)
125
+ SharedExampleGroup.should include(shared_example_group)
106
126
  end
107
127
  end
108
128
 
@@ -131,8 +151,8 @@ module Spec
131
151
  Spec::Example::ExampleGroupFactory.reset
132
152
  end
133
153
  end
134
-
135
- describe "#all_registered?" do
154
+
155
+ describe "#registered_or_ancestor_of_registered?" do
136
156
  before(:each) do
137
157
  @unregistered_parent = Class.new(ExampleGroup)
138
158
  @registered_child = Class.new(@unregistered_parent)
@@ -141,19 +161,19 @@ module Spec
141
161
  end
142
162
 
143
163
  it "should return true for empty list" do
144
- Spec::Example::ExampleGroupFactory.all_registered?([]).should be_true
164
+ Spec::Example::ExampleGroupFactory.registered_or_ancestor_of_registered?([]).should be_true
145
165
  end
146
166
 
147
167
  it "should return true for a registered example group class" do
148
- Spec::Example::ExampleGroupFactory.all_registered?([@registered_child]).should be_true
168
+ Spec::Example::ExampleGroupFactory.registered_or_ancestor_of_registered?([@registered_child]).should be_true
149
169
  end
150
170
 
151
171
  it "should return true for an ancestor of a registered example_group_classes" do
152
- Spec::Example::ExampleGroupFactory.all_registered?([@unregistered_parent]).should be_true
172
+ Spec::Example::ExampleGroupFactory.registered_or_ancestor_of_registered?([@unregistered_parent]).should be_true
153
173
  end
154
174
 
155
175
  it "should return false for a subclass of a registered example_group_class" do
156
- Spec::Example::ExampleGroupFactory.all_registered?([@unregistered_grandchild]).should be_false
176
+ Spec::Example::ExampleGroupFactory.registered_or_ancestor_of_registered?([@unregistered_grandchild]).should be_false
157
177
  end
158
178
 
159
179
  after(:each) do
@@ -50,7 +50,7 @@ module Spec
50
50
 
51
51
  describe "when creating a SharedExampleGroup" do
52
52
  attr_reader :name, :shared_example_group
53
- before do
53
+ before(:each) do
54
54
  @name = "A Shared ExampleGroup"
55
55
  @shared_example_group = @example_group.send method, name, :shared => true do
56
56
  it "should pass" do
@@ -59,14 +59,12 @@ module Spec
59
59
  end
60
60
  end
61
61
 
62
- after do
63
- SharedExampleGroup.shared_example_groups.delete_if do |registered_shared_example_group|
64
- registered_shared_example_group == shared_example_group
65
- end
62
+ after(:each) do
63
+ SharedExampleGroup.clear
66
64
  end
67
65
 
68
66
  it "should create a SharedExampleGroup" do
69
- SharedExampleGroup.find_shared_example_group(name).should == shared_example_group
67
+ SharedExampleGroup.find(name).should == shared_example_group
70
68
  end
71
69
  end
72
70
 
@@ -673,11 +673,5 @@ module Spec
673
673
  $nested_group.description.to_s.should == "Array when empty"
674
674
  end
675
675
  end
676
-
677
- describe String do
678
- it "should not be included in examples because it is not a module" do
679
- lambda{self.map}.should raise_error(NoMethodError, /undefined method `map' for/)
680
- end
681
- end
682
676
  end
683
677
  end
@@ -2,31 +2,14 @@ require File.dirname(__FILE__) + '/../../spec_helper.rb'
2
2
 
3
3
  module Spec
4
4
  module Example
5
- module ExampleMatcherSpecHelper
6
- class MatchDescription
7
- def initialize(description)
8
- @description = description
9
- end
10
-
11
- def matches?(matcher)
12
- matcher.matches?(@description)
13
- end
14
-
15
- def failure_message
16
- "expected matcher.matches?(#{@description.inspect}) to return true, got false"
17
- end
18
-
19
- def negative_failure_message
20
- "expected matcher.matches?(#{@description.inspect}) to return false, got true"
21
- end
22
- end
5
+ describe ExampleMatcher, "#matches?" do
23
6
  def match_description(description)
24
- MatchDescription.new(description)
7
+ simple_matcher do |actual, matcher|
8
+ matcher.failure_message = "expected matcher.matches?(#{description.inspect}) to return true, got false"
9
+ matcher.negative_failure_message = "expected matcher.matches?(#{description.inspect}) to return false, got true"
10
+ actual.matches?(description)
11
+ end
25
12
  end
26
- end
27
-
28
- describe ExampleMatcher, "#matches?" do
29
- include ExampleMatcherSpecHelper
30
13
 
31
14
  it "should match correct example_group and example" do
32
15
  matcher = ExampleMatcher.new("example_group", "example")