Class: Busser::RunnerPlugin::Shindo

Inherits:
Base
  • Object
show all
Defined in:
lib/busser/runner_plugin/shindo.rb

Overview

A Busser runner plugin for Shindo.

Author:

Instance Method Summary collapse

Instance Method Details

#testObject



32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
# File 'lib/busser/runner_plugin/shindo.rb', line 32

def test
  ## Refered from busser-rspec
  gemfile_path = File.join(suite_path, 'shindo', 'Gemfile')
  if File.exists?(gemfile_path)
  # Bundle install local completes quickly if the gems are already found locally
  # it fails if it needs to talk to the internet. The || below is the fallback
  # to the internet-enabled version. It's a speed optimization.
    banner('Bundle Installing..')
    ENV['PATH'] = [ENV['PATH'], Gem.bindir].join(':')
    bundle_option = "--gemfile #{gemfile_path}"
    run("bundle install --local #{bundle_option} || bundle install #{bundle_option}")
  end

  banner('run shindont')
  run!("cd #{suite_path('shindo')} && env PATH=#{ENV['PATH']}:#{Gem.bindir} shindont")
end