summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTyler Ball <tyler-ball@users.noreply.github.com>2016-01-20 16:39:29 -0700
committerTyler Ball <tyler-ball@users.noreply.github.com>2016-01-20 16:39:29 -0700
commit38e4b8ad4a1d701878595c7822636f3cbb7f7af9 (patch)
tree4873359cc43607ad72da6966e3bd4b6b26d851bb
parenta6d897235eecca34629e9d7330c2ba5e7a8ab3fe (diff)
parent5cf2266414afa29851c81fffbf7d593ba9810de6 (diff)
downloadchef-38e4b8ad4a1d701878595c7822636f3cbb7f7af9.tar.gz
Merge pull request #4439 from chef/tball/win2008r2_test_failures
Sometimes chocolately doesn't appear on the path
-rw-r--r--spec/functional/resource/chocolatey_package_spec.rb3
1 files changed, 3 insertions, 0 deletions
diff --git a/spec/functional/resource/chocolatey_package_spec.rb b/spec/functional/resource/chocolatey_package_spec.rb
index 39baa7ffce..7cbaaf0d6b 100644
--- a/spec/functional/resource/chocolatey_package_spec.rb
+++ b/spec/functional/resource/chocolatey_package_spec.rb
@@ -23,6 +23,9 @@ describe Chef::Resource::ChocolateyPackage, :windows_only do
before(:all) do
powershell_out!("iex ((new-object net.webclient).DownloadString('https://chocolatey.org/install.ps1'))")
+ unless ENV["PATH"] =~ /chocolatey\\bin/
+ ENV["PATH"] = "C:\\ProgramData\\chocolatey\\bin;#{ENV["PATH"]}"
+ end
end
let(:package_name) { "test-A" }