Class: PkgForge::DSL::Test

Inherits:
Base
  • Object
show all
Defined in:
lib/pkgforge/components/test.rb,
lib/pkgforge/base.rb

Overview

Add test methods to Test DSL

Instance Method Summary collapse

Methods inherited from Base

#initialize

Constructor Details

This class inherits a constructor from PkgForge::Base

Instance Method Details

#run(cmd, env = {}) ⇒ Object



36
37
38
39
40
41
42
# File 'lib/pkgforge/components/test.rb', line 36

def run(cmd, env = {})
  cmd.unshift('/usr/bin/env') if cmd.is_a? Array
  cmd << ';' if cmd.is_a? String
  env['PATH'] ||= './usr/bin'
  env['LD_LIBRARY_PATH'] ||= ld_library_path
  @forge.test_run(cmd, env)
end