2020-03-21 00:46:45 +01:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2020-06-11 03:21:18 +02:00
|
|
|
services =
|
|
|
|
case platform[:family]
|
|
|
|
when 'windows'
|
|
|
|
%w[salt-minion]
|
|
|
|
else
|
|
|
|
%w[salt-master salt-minion]
|
|
|
|
end
|
|
|
|
|
2020-03-21 00:46:45 +01:00
|
|
|
control 'salt services' do
|
|
|
|
title 'should be running'
|
|
|
|
|
2020-06-11 03:21:18 +02:00
|
|
|
services.each do |p|
|
2020-03-21 00:46:45 +01:00
|
|
|
describe service(p) do
|
2020-04-02 00:22:05 +02:00
|
|
|
it { should be_installed }
|
2020-03-21 00:46:45 +01:00
|
|
|
it { should be_enabled }
|
|
|
|
it { should be_running }
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|