Method: Rspec2Adapter.command

Defined in:
lib/shared/adapters/rspec2_adapter.rb

.command(project_path, ruby_interpreter, files) ⇒ Object



5
6
7
8
9
10
11
12
13
14
15
# File 'lib/shared/adapters/rspec2_adapter.rb', line 5

def self.command(project_path, ruby_interpreter, files)
  spec_command = RubyEnv.ruby_command(project_path,
    :bin => "rspec",
    :ruby_interpreter => ruby_interpreter)

  if File.exists?("#{project_path}/spec/spec.opts")
    spec_command += " -O spec/spec.opts"
  end

  "export RSPEC_COLOR=true; #{spec_command} #{files}"
end