diff options
author | Matt Wrock <matt@mattwrock.com> | 2016-01-19 11:26:08 -0800 |
---|---|---|
committer | Matt Wrock <matt@mattwrock.com> | 2016-01-19 11:51:55 -0800 |
commit | eacdbae976c05cccb6550d04f664034b9e66448f (patch) | |
tree | 89978620ad1860647175603f246b9a081c271807 /spec/unit/windows_service_spec.rb | |
parent | 600f83f177370adbd916666190989054d6fae1f0 (diff) | |
download | chef-eacdbae976c05cccb6550d04f664034b9e66448f.tar.gz |
explicitly adding .bat to service executable called by service in case users remove .bat from PATHEXT
Diffstat (limited to 'spec/unit/windows_service_spec.rb')
-rw-r--r-- | spec/unit/windows_service_spec.rb | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/spec/unit/windows_service_spec.rb b/spec/unit/windows_service_spec.rb index a614e6630d..6752b19a7b 100644 --- a/spec/unit/windows_service_spec.rb +++ b/spec/unit/windows_service_spec.rb @@ -51,7 +51,7 @@ describe "Chef::Application::WindowsService", :windows_only do it "passes DEFAULT_LOG_LOCATION to chef-client instead of STDOUT" do expect(subject).to receive(:shell_out).with( - "chef-client --no-fork -c test_config_file -L #{Chef::Application::WindowsService::DEFAULT_LOG_LOCATION}", + "chef-client.bat --no-fork -c test_config_file -L #{Chef::Application::WindowsService::DEFAULT_LOG_LOCATION}", shellout_options, ).and_return(shell_out_result) subject.service_main @@ -73,7 +73,7 @@ describe "Chef::Application::WindowsService", :windows_only do it "uses the configured log location" do expect(subject).to receive(:shell_out).with( - "chef-client --no-fork -c test_config_file -L #{tempfile.path}", + "chef-client.bat --no-fork -c test_config_file -L #{tempfile.path}", shellout_options, ).and_return(shell_out_result) subject.service_main @@ -90,7 +90,7 @@ describe "Chef::Application::WindowsService", :windows_only do it "does not pass log location to new process" do expect(subject).to receive(:shell_out).with( - "chef-client --no-fork -c test_config_file", + "chef-client.bat --no-fork -c test_config_file", shellout_options, ).and_return(shell_out_result) subject.service_main @@ -107,7 +107,7 @@ describe "Chef::Application::WindowsService", :windows_only do it "passes watchdog timeout to new process" do expect(subject).to receive(:shell_out).with( - "chef-client --no-fork -c test_config_file -L #{Chef::Application::WindowsService::DEFAULT_LOG_LOCATION}", + "chef-client.bat --no-fork -c test_config_file -L #{Chef::Application::WindowsService::DEFAULT_LOG_LOCATION}", shellout_options, ).and_return(shell_out_result) subject.service_main |