diff options
author | John Duarte <john.duarte@puppetlabs.com> | 2014-05-15 11:43:29 -0700 |
---|---|---|
committer | John Duarte <john.duarte@puppetlabs.com> | 2014-05-18 11:38:20 -0700 |
commit | 97e64b52f63f3dd673dfa2fe92c71d4d9ddbcbc7 (patch) | |
tree | 7c67a56ccf64768392b0eb5e7c7061cb31b33375 /spec/acceptance/beaker/git/revision_checkout | |
parent | 3d35e61e4377e73365b9f7c340b225d787fe3cbb (diff) | |
download | puppet-vcsrepo-97e64b52f63f3dd673dfa2fe92c71d4d9ddbcbc7.tar.gz puppet-vcsrepo-97e64b52f63f3dd673dfa2fe92c71d4d9ddbcbc7.tar.bz2 |
Add conditional ruby path based on pe
Diffstat (limited to 'spec/acceptance/beaker/git/revision_checkout')
-rw-r--r-- | spec/acceptance/beaker/git/revision_checkout/revision_checkout_http.rb | 5 | ||||
-rw-r--r-- | spec/acceptance/beaker/git/revision_checkout/revision_checkout_https.rb | 5 |
2 files changed, 6 insertions, 4 deletions
diff --git a/spec/acceptance/beaker/git/revision_checkout/revision_checkout_http.rb b/spec/acceptance/beaker/git/revision_checkout/revision_checkout_http.rb index 40db6c9..5f5d9e5 100644 --- a/spec/acceptance/beaker/git/revision_checkout/revision_checkout_http.rb +++ b/spec/acceptance/beaker/git/revision_checkout/revision_checkout_http.rb @@ -4,6 +4,7 @@ test_name 'C3455 - checkout a revision (http protocol)' repo_name = 'testrepo_revision_checkout' hosts.each do |host| + ruby = '/opt/puppet/bin/ruby' if host.is_pe? || 'ruby' tmpdir = host.tmpdir('vcsrepo') step 'setup - create repo' do install_package(host, 'git') @@ -20,12 +21,12 @@ hosts.each do |host| server.start EOF create_remote_file(host, '/tmp/http_daemon.rb', http_daemon) - on(host, "ruby /tmp/http_daemon.rb") + on(host, "#{ruby} /tmp/http_daemon.rb") end teardown do on(host, "rm -fr #{tmpdir}") - on(host, 'ps ax | grep "ruby /tmp/http_daemon.rb" | grep -v grep | awk \'{print "kill -9 " $1}\' | sh') + on(host, 'ps ax | grep "#{ruby} /tmp/http_daemon.rb" | grep -v grep | awk \'{print "kill -9 " $1}\' | sh') end step 'get revision sha from repo' do diff --git a/spec/acceptance/beaker/git/revision_checkout/revision_checkout_https.rb b/spec/acceptance/beaker/git/revision_checkout/revision_checkout_https.rb index dc3dc7f..0a935aa 100644 --- a/spec/acceptance/beaker/git/revision_checkout/revision_checkout_https.rb +++ b/spec/acceptance/beaker/git/revision_checkout/revision_checkout_https.rb @@ -4,6 +4,7 @@ test_name 'C3456 - checkout a revision (https protocol)' repo_name = 'testrepo_revision_checkout' hosts.each do |host| + ruby = '/opt/puppet/bin/ruby' if host.is_pe? || 'ruby' tmpdir = host.tmpdir('vcsrepo') step 'setup - create repo' do install_package(host, 'git') @@ -27,12 +28,12 @@ hosts.each do |host| server.start EOF create_remote_file(host, '/tmp/https_daemon.rb', https_daemon) - #on(host, "ruby /tmp/https_daemon.rb") + #on(host, "#{ruby} /tmp/https_daemon.rb") end teardown do on(host, "rm -fr #{tmpdir}") - on(host, 'ps ax | grep "ruby /tmp/https_daemon.rb" | grep -v grep | awk \'{print "kill -9 " $1}\' | sh') + on(host, 'ps ax | grep "#{ruby} /tmp/https_daemon.rb" | grep -v grep | awk \'{print "kill -9 " $1}\' | sh') end step 'get revision sha from repo' do |