puppet-manila/spec/defines/manila_backend_glusterfs_spec.rb
Iury Gregory Melo Ferreira e6ab8881ee Manila $::os_service_default for db and log
Switch to $::os_service_default all params in logging and db.
Changes: logging.pp, db.pp and tests.

Related-bug: #1515273

Change-Id: Idf7bc36d321328391a1b361add965c53627124a4
2015-11-25 13:57:58 +00:00

44 lines
1.2 KiB
Ruby

require 'spec_helper'
describe 'manila::backend::glusterfs' do
shared_examples_for 'glusterfs share driver' do
let(:title) {'mygluster'}
let :params do
{
:glusterfs_volumes_config => '/etc/manila/glusterfs_volumes',
:glusterfs_mount_point_base => '$state_path/mnt',
}
end
it 'configures glusterfs share driver' do
is_expected.to contain_manila_config('mygluster/share_backend_name').with_value(
'mygluster')
is_expected.to contain_manila_config('mygluster/share_driver').with_value(
'manila.share.drivers.glusterfs.GlusterfsShareDriver')
is_expected.to contain_manila_config('mygluster/glusterfs_volumes_config').with_value(
'/etc/manila/glusterfs_volumes')
is_expected.to contain_manila_config('mygluster/glusterfs_mount_point_base').with_value(
'$state_path/mnt')
end
end
context 'on Debian platforms' do
let :facts do
@default_facts.merge({ :osfamily => 'Debian' })
end
it_configures 'glusterfs share driver'
end
context 'on RedHat platforms' do
let :facts do
@default_facts.merge({ :osfamily => 'RedHat' })
end
it_configures 'glusterfs share driver'
end
end