summaryrefslogtreecommitdiff
path: root/puppet/modules/ntp/spec/system/restrict_spec.rb
diff options
context:
space:
mode:
authorMicah <micah@leap.se>2016-05-24 10:19:24 -0400
committerMicah <micah@leap.se>2016-05-24 10:19:24 -0400
commit3ff2bbfa2bcf9d70e2df1e3e8c9336f18c2217b7 (patch)
treeaa3e31b19b135fe224c9787ba388a663c59789e9 /puppet/modules/ntp/spec/system/restrict_spec.rb
parent6affc72f829247fc78b637c27f47cf8bf6beafb7 (diff)
parentb6b29da6f63d5d04f2d587dfa2227b1d6c9ecded (diff)
Merge commit 'b6b29da6f63d5d04f2d587dfa2227b1d6c9ecded' as 'puppet/modules/ntp'
Diffstat (limited to 'puppet/modules/ntp/spec/system/restrict_spec.rb')
-rw-r--r--puppet/modules/ntp/spec/system/restrict_spec.rb20
1 files changed, 20 insertions, 0 deletions
diff --git a/puppet/modules/ntp/spec/system/restrict_spec.rb b/puppet/modules/ntp/spec/system/restrict_spec.rb
new file mode 100644
index 00000000..ae23bc01
--- /dev/null
+++ b/puppet/modules/ntp/spec/system/restrict_spec.rb
@@ -0,0 +1,20 @@
+require 'spec_helper_system'
+
+describe "ntp class with restrict:" do
+ context 'should run successfully' do
+ pp = "class { 'ntp': restrict => ['test restrict']}"
+
+ context puppet_apply(pp) do
+ its(:stderr) { should be_empty }
+ its(:exit_code) { should_not == 1 }
+ its(:refresh) { should be_nil }
+ its(:stderr) { should be_empty }
+ its(:exit_code) { should be_zero }
+ end
+ end
+
+ describe file('/etc/ntp.conf') do
+ it { should contain('test restrict') }
+ end
+
+end