diff options
Diffstat (limited to 'spec/unit/provider/service/openbsd_service_spec.rb')
-rw-r--r-- | spec/unit/provider/service/openbsd_service_spec.rb | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/spec/unit/provider/service/openbsd_service_spec.rb b/spec/unit/provider/service/openbsd_service_spec.rb index 913fddc1cf..9cb8a2b5dc 100644 --- a/spec/unit/provider/service/openbsd_service_spec.rb +++ b/spec/unit/provider/service/openbsd_service_spec.rb @@ -286,12 +286,12 @@ describe Chef::Provider::Service::Openbsd do it "should call the start command if one is specified" do new_resource.start_command("/etc/rc.d/chef startyousillysally") expect(provider).to receive(:shell_out!).with("/etc/rc.d/chef startyousillysally", default_env: false) - provider.start_service() + provider.start_service end it "should call '/usr/local/etc/rc.d/service_name start' if no start command is specified" do expect(provider).to receive(:shell_out!).with("/etc/rc.d/#{new_resource.service_name} start", default_env: false) - provider.start_service() + provider.start_service end end @@ -299,12 +299,12 @@ describe Chef::Provider::Service::Openbsd do it "should call the stop command if one is specified" do new_resource.stop_command("/etc/init.d/chef itoldyoutostop") expect(provider).to receive(:shell_out!).with("/etc/init.d/chef itoldyoutostop", default_env: false) - provider.stop_service() + provider.stop_service end it "should call '/usr/local/etc/rc.d/service_name stop' if no stop command is specified" do expect(provider).to receive(:shell_out!).with("/etc/rc.d/#{new_resource.service_name} stop", default_env: false) - provider.stop_service() + provider.stop_service end end @@ -313,20 +313,20 @@ describe Chef::Provider::Service::Openbsd do let(:supports) { { restart: true } } it "should call 'restart' on the service_name if the resource supports it" do expect(provider).to receive(:shell_out!).with("/etc/rc.d/#{new_resource.service_name} restart", default_env: false) - provider.restart_service() + provider.restart_service end end it "should call the restart_command if one has been specified" do new_resource.restart_command("/etc/init.d/chef restartinafire") expect(provider).to receive(:shell_out!).with("/etc/init.d/chef restartinafire", default_env: false) - provider.restart_service() + provider.restart_service end it "otherwise it should call stop and start" do expect(provider).to receive(:stop_service) expect(provider).to receive(:start_service) - provider.restart_service() + provider.restart_service end end end |