
Add a new class nova::config which allows the creation and management of arbitrary nova_config and nova_api_paste_ini resources. This will add the ability for the end user to use Hiera to manage those resources. Change-Id: Iad7a2b764884887a75f5f6db3e1660644e07c5c0 Closes-bug: #1290634
31 lines
1.0 KiB
Ruby
31 lines
1.0 KiB
Ruby
require 'spec_helper'
|
|
|
|
describe 'nova::config' do
|
|
|
|
let :params do
|
|
{ :nova_config => {
|
|
'DEFAULT/foo' => { 'value' => 'fooValue' },
|
|
'DEFAULT/bar' => { 'value' => 'barValue' },
|
|
'DEFAULT/baz' => { 'ensure' => 'absent' }
|
|
},
|
|
:nova_paste_api_ini => {
|
|
'DEFAULT/foo2' => { 'value' => 'fooValue' },
|
|
'DEFAULT/bar2' => { 'value' => 'barValue' },
|
|
'DEFAULT/baz2' => { 'ensure' => 'absent' }
|
|
}
|
|
}
|
|
end
|
|
|
|
it 'configures arbitrary nova configurations' do
|
|
should contain_nova_config('DEFAULT/foo').with_value('fooValue')
|
|
should contain_nova_config('DEFAULT/bar').with_value('barValue')
|
|
should contain_nova_config('DEFAULT/baz').with_ensure('absent')
|
|
end
|
|
|
|
it 'configures arbitrary nova api-paste configurations' do
|
|
should contain_nova_paste_api_ini('DEFAULT/foo2').with_value('fooValue')
|
|
should contain_nova_paste_api_ini('DEFAULT/bar2').with_value('barValue')
|
|
should contain_nova_paste_api_ini('DEFAULT/baz2').with_ensure('absent')
|
|
end
|
|
end
|