Class: MRspec::Runner

Inherits:
RSpec::Core::Runner
  • Object
show all
Defined in:
lib/mrspec/runner.rb

Instance Method Summary collapse

Constructor Details

#initializeRunner

Returns a new instance of Runner.



5
6
7
8
9
10
11
12
# File 'lib/mrspec/runner.rb', line 5

def initialize(*)
  super
  # seems like there should be a better way, but I can't figure out what it is
  files_and_dirs = @options.options[:files_or_directories_to_run]
  return if files_and_dirs.any?
  files_and_dirs << 'spec' if File.directory? 'spec'
  files_and_dirs << 'test' if File.directory? 'test'
end