diff options
author | Adam Jahn <ajjahn@gmail.com> | 2016-07-10 14:30:46 -0400 |
---|---|---|
committer | Adam Jahn <ajjahn@gmail.com> | 2016-07-10 14:30:46 -0400 |
commit | 0831bc6db6914e8da7cdde08f05bba5ec9119179 (patch) | |
tree | 135fcd1231799c96886be6fd9de900e2b7bef8c8 /spec/defines | |
parent | 36b2f12d930cd8e552ec8a3d640c116b70b844e5 (diff) | |
download | puppet-samba-0831bc6db6914e8da7cdde08f05bba5ec9119179.tar.gz puppet-samba-0831bc6db6914e8da7cdde08f05bba5ec9119179.tar.bz2 |
specs for inherit permissions option, closes #67
Diffstat (limited to 'spec/defines')
-rw-r--r-- | spec/defines/samba__server__share_spec.rb | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/spec/defines/samba__server__share_spec.rb b/spec/defines/samba__server__share_spec.rb index f6d1925..876d3f8 100644 --- a/spec/defines/samba__server__share_spec.rb +++ b/spec/defines/samba__server__share_spec.rb @@ -38,6 +38,7 @@ shared_examples "default share" do set.with("write list") set.with("hide dot files") set.with("root preexec") + set.with("inherit permissions") end let(:change_set) { default_changes } let(:changes) { change_set.to_a } @@ -586,6 +587,24 @@ describe 'samba::server::share', :type => :define do }} let(:change_set) { default_changes.with("root preexec", "'/bin/test'") } end + + context 'with inherit_permissions set to true' do + include_examples "default share" + let(:params) {{ + :ensure => 'present', + :inherit_permissions => true, + }} + let(:change_set) { default_changes.with("inherit permissions", "yes") } + end + + context 'with inherit_permissions set to false' do + include_examples "default share" + let(:params) {{ + :ensure => 'present', + :inherit_permissions => false, + }} + let(:change_set) { default_changes.with("inherit permissions", "no") } + end end end end |