1 require 'spec_helper_acceptance'
3 describe 'apache::mod::dav_svn class', :unless => (fact('operatingsystem') == 'OracleLinux' and fact('operatingsystemmajrelease') == '7') do
6 mod_dir = '/etc/apache2/mods-available'
7 service_name = 'apache2'
8 if fact('operatingsystemmajrelease') == '6' or fact('operatingsystemmajrelease') == '10.04' or fact('operatingsystemrelease') == '10.04'
9 authz_svn_load_file = 'dav_svn_authz_svn.load'
11 authz_svn_load_file = 'authz_svn.load'
14 mod_dir = '/etc/httpd/conf.d'
15 service_name = 'httpd'
16 authz_svn_load_file = 'dav_svn_authz_svn.load'
18 mod_dir = '/usr/local/etc/apache24/Modules'
19 service_name = 'apache24'
20 authz_svn_load_file = 'dav_svn_authz_svn.load'
23 context "default dav_svn config" do
24 it 'succeeds in puppeting dav_svn' do
27 include apache::mod::dav_svn
29 apply_manifest(pp, :catch_failures => true)
32 describe service(service_name) do
33 it { is_expected.to be_enabled }
34 it { is_expected.to be_running }
37 describe file("#{mod_dir}/dav_svn.load") do
38 it { is_expected.to contain "LoadModule dav_svn_module" }
42 context "dav_svn with enabled authz_svn config" do
43 it 'succeeds in puppeting dav_svn' do
46 class { 'apache::mod::dav_svn':
47 authz_svn_enabled => true,
50 apply_manifest(pp, :catch_failures => true)
53 describe service(service_name) do
54 it { is_expected.to be_enabled }
55 it { is_expected.to be_running }
58 describe file("#{mod_dir}/#{authz_svn_load_file}") do
59 it { is_expected.to contain "LoadModule authz_svn_module" }