summaryrefslogtreecommitdiff
path: root/spec/system/ntp_service_spec.rb
blob: b97e2a4e1ff3ade953636ec18973a01d25c56fcc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
require 'spec_helper_system'


describe 'ntp::service class' do
  let(:os) {
    node.facts['osfamily']
  }

  case node.facts['osfamily']
  when 'RedHat', 'FreeBSD', 'Linux'
    servicename = 'ntpd'
  else
    servicename = 'ntp'
  end

  puppet_apply(%{
    class { 'ntp': }
  })

  describe service(servicename) do
    it { should be_enabled }
    it { should be_running }
  end

end