summaryrefslogtreecommitdiff
path: root/tasks
diff options
context:
space:
mode:
authorLamont Granquist <lamont@scriptkiddie.org>2018-04-23 13:16:52 -0700
committerLamont Granquist <lamont@scriptkiddie.org>2018-04-23 13:18:05 -0700
commite9cedd0d497812a5f481ec55c9096bd8ee2d2aae (patch)
tree4352766f504368a1855dad44af17e73cae9ec0f2 /tasks
parent0e5ad786acf652f9a537c8e5cb4dd7c6401c438e (diff)
downloadchef-e9cedd0d497812a5f481ec55c9096bd8ee2d2aae.tar.gz
test chef-zero against chef_fs in the chef/chef checkout
goes red because we're really red here Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
Diffstat (limited to 'tasks')
-rwxr-xr-xtasks/bin/run_external_test8
1 files changed, 6 insertions, 2 deletions
diff --git a/tasks/bin/run_external_test b/tasks/bin/run_external_test
index 1925c3e125..01eba18943 100755
--- a/tasks/bin/run_external_test
+++ b/tasks/bin/run_external_test
@@ -11,6 +11,10 @@ include Chef::Mixin::ShellOut
github_repo = ARGV.shift
git_thing = ARGV.shift
+build_dir = File.expand_path(ENV["TRAVIS_BUILD_DIR"] || Dir.pwd)
+
+env = { "GEMFILE_MOD" => "gem 'chef', path: '#{build_dir}'" }
+
Dir.mktmpdir("chef-external-test") do |dir|
git_url = "https://github.com/#{github_repo}"
Dir.rmdir dir
@@ -18,8 +22,8 @@ Dir.mktmpdir("chef-external-test") do |dir|
Dir.chdir(dir) do
shell_out!("git checkout #{git_thing}", live_stream: STDOUT)
Bundler.with_clean_env do
- shell_out!("bundle install", live_stream: STDOUT)
- shell_out!("bundle exec #{ARGV.join(" ")}", live_stream: STDOUT)
+ shell_out!("bundle install", live_stream: STDOUT, env: env)
+ shell_out!("bundle exec #{ARGV.join(" ")}", live_stream: STDOUT, env: env)
end
end
end