Class: Mutant::Rspec::Strategy
- Inherits:
-
Strategy
- Object
- Strategy
- Mutant::Rspec::Strategy
- Defined in:
- lib/mutant/rspec/strategy.rb
Overview
Rspec killer strategy
Constant Summary collapse
Instance Method Summary collapse
-
#configuration ⇒ RSpec::Core::Configuration
private
Return configuration.
-
#example_groups ⇒ Enumerable<RSpec::Core::ExampleGroup>
private
Return example groups.
-
#rspec2? ⇒ true, false
private
Detect RSpec 2.
-
#setup ⇒ self
private
Setup rspec strategy.
Instance Method Details
#configuration ⇒ RSpec::Core::Configuration
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Return configuration
34 35 36 |
# File 'lib/mutant/rspec/strategy.rb', line 34 def configuration RSpec::Core::Configuration.new end |
#example_groups ⇒ Enumerable<RSpec::Core::ExampleGroup>
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Return example groups
45 46 47 |
# File 'lib/mutant/rspec/strategy.rb', line 45 def example_groups world.example_groups end |
#rspec2? ⇒ true, false
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Detect RSpec 2
59 60 61 |
# File 'lib/mutant/rspec/strategy.rb', line 59 def rspec2? RSpec::Core::Version::STRING.start_with?('2.') end |
#setup ⇒ self
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Setup rspec strategy
18 19 20 21 22 23 24 25 |
# File 'lib/mutant/rspec/strategy.rb', line 18 def setup output = StringIO.new configuration.error_stream = output configuration.output_stream = output .configure(configuration) configuration.load_spec_files self end |