Tag all Sahara packages
Some users wish to override the default package provider by their own. Tag all packages with the 'openstack' to allow mass resource attributes override using resource collectors. Change-Id: Ic662043bcd19a930a47a6716be051561fceef5d7 Closes-bug: #1391209 Signed-off-by: Gael Chamoulaud <gchamoul@redhat.com>
This commit is contained in:
parent
5daa68f89c
commit
303e514db0
@ -17,5 +17,6 @@ class sahara::client (
|
|||||||
package { 'python-saharaclient':
|
package { 'python-saharaclient':
|
||||||
ensure => $package_ensure,
|
ensure => $package_ensure,
|
||||||
name => $::sahara::params::client_package_name,
|
name => $::sahara::params::client_package_name,
|
||||||
|
tag => 'openstack',
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -120,6 +120,7 @@ class sahara(
|
|||||||
package { 'sahara':
|
package { 'sahara':
|
||||||
ensure => $package_ensure,
|
ensure => $package_ensure,
|
||||||
name => $::sahara::params::package_name,
|
name => $::sahara::params::package_name,
|
||||||
|
tag => 'openstack',
|
||||||
}
|
}
|
||||||
|
|
||||||
Package['sahara'] -> Sahara_config<||>
|
Package['sahara'] -> Sahara_config<||>
|
||||||
|
@ -8,14 +8,22 @@ describe 'sahara::client' do
|
|||||||
shared_examples_for 'sahara client' do
|
shared_examples_for 'sahara client' do
|
||||||
|
|
||||||
context 'with default parameters' do
|
context 'with default parameters' do
|
||||||
it { is_expected.to contain_package('python-saharaclient').with_ensure('present') }
|
it { is_expected.to contain_package('python-saharaclient').with(
|
||||||
|
:ensure => 'present',
|
||||||
|
:tag => 'openstack',
|
||||||
|
)
|
||||||
|
}
|
||||||
end
|
end
|
||||||
|
|
||||||
context 'with package_ensure parameter provided' do
|
context 'with package_ensure parameter provided' do
|
||||||
let :params do
|
let :params do
|
||||||
{ :package_ensure => false }
|
{ :package_ensure => false }
|
||||||
end
|
end
|
||||||
it { is_expected.to contain_package('python-saharaclient').with_ensure('false') }
|
it { is_expected.to contain_package('python-saharaclient').with(
|
||||||
|
:ensure => false,
|
||||||
|
:tag => 'openstack',
|
||||||
|
)
|
||||||
|
}
|
||||||
end
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
|
Loading…
Reference in New Issue
Block a user