
This patch aim to update our specs test in order to work with the new rspec-puppet release 2.0.0, in the mean time, we update rspec syntax in order to be prepared for rspec 3.x move. In details: * Convert 'should' keyword to 'is_expected.to' (prepare rspec 3.x) * Upgrade and pin rspec-puppet from 1.0.1 to 2.0.0 * Clean Gemfile (remove over-specificication of runtime deps of puppetlabs_spec_helper) Change-Id: I062afe69fea8acb4785c537df7400d9c5d7034b4 Signed-off-by: Gael Chamoulaud <gchamoul@redhat.com>
31 lines
1.1 KiB
Ruby
31 lines
1.1 KiB
Ruby
require 'spec_helper'
|
|
|
|
describe 'manila::share::generic' do
|
|
|
|
let :params do
|
|
{
|
|
:smb_template_config_path => '$state_path/smb.conf',
|
|
:volume_name_template => 'manila-share-%s',
|
|
:volume_snapshot_name_template => 'manila-snapshot-%s',
|
|
:share_mount_path => '/shares',
|
|
:max_time_to_create_volume => 180,
|
|
:max_time_to_attach => 120,
|
|
:service_instance_smb_config_path => '$share_mount_path/smb.conf',
|
|
:share_volume_fstype => 'ext4',
|
|
}
|
|
end
|
|
|
|
describe 'generic share driver' do
|
|
it 'configures generic share driver' do
|
|
is_expected.to contain_manila_config('DEFAULT/share_driver').with_value(
|
|
'manila.share.drivers.generic.GenericShareDriver')
|
|
is_expected.to contain_manila_config('DEFAULT/share_helpers').with_value(
|
|
'CIFS=manila.share.drivers.generic.CIFSHelper,'\
|
|
'NFS=manila.share.drivers.generic.NFSHelper')
|
|
params.each_pair do |config,value|
|
|
is_expected.to contain_manila_config("DEFAULT/#{config}").with_value( value )
|
|
end
|
|
end
|
|
end
|
|
end
|