Class: Specjour::RSpec::Preloader

Inherits:
Object
  • Object
show all
Defined in:
lib/specjour/rspec/preloader.rb

Class Method Summary collapse

Class Method Details

.load(paths = []) ⇒ Object



2
3
4
5
6
# File 'lib/specjour/rspec/preloader.rb', line 2

def self.load(paths=[])
  $stdout.puts "Loading RSpec Environment"
  require './spec/spec_helper'
  load_spec_files paths
end

.load_spec_files(paths) ⇒ Object



8
9
10
11
12
13
# File 'lib/specjour/rspec/preloader.rb', line 8

def self.load_spec_files(paths)
  options = ::RSpec::Core::ConfigurationOptions.new(paths)
  options.parse_options
  options.configure ::RSpec.configuration
  ::RSpec.configuration.load_spec_files
end