Merge "Inherit pyvers from openstacklib::defaults"
This commit is contained in:
commit
e2cad3594b
@ -2,13 +2,7 @@
|
||||
#
|
||||
class aodh::params {
|
||||
include ::openstacklib::defaults
|
||||
|
||||
if ($::os_package_type == 'debian') or ($::os['name'] == 'Fedora') or
|
||||
($::os['family'] == 'RedHat' and Integer.new($::os['release']['major']) > 7) {
|
||||
$pyvers = '3'
|
||||
} else {
|
||||
$pyvers = ''
|
||||
}
|
||||
$pyvers = $::openstacklib::defaults::pyvers
|
||||
|
||||
$client_package_name = "python${pyvers}-aodhclient"
|
||||
$group = 'aodh'
|
||||
|
@ -10,7 +10,7 @@ describe 'aodh::client' do
|
||||
it 'installs aodh client package' do
|
||||
is_expected.to contain_package('python-aodhclient').with(
|
||||
:ensure => 'present',
|
||||
:name => 'python-aodhclient',
|
||||
:name => platform_params[:client_package_name],
|
||||
:tag => 'openstack',
|
||||
)
|
||||
end
|
||||
@ -27,11 +27,7 @@ describe 'aodh::client' do
|
||||
let(:platform_params) do
|
||||
case facts[:osfamily]
|
||||
when 'Debian'
|
||||
if facts[:os_package_type] == 'debian'
|
||||
{ :client_package_name => 'python3-aodhclient' }
|
||||
else
|
||||
{ :client_package_name => 'python-aodhclient' }
|
||||
end
|
||||
{ :client_package_name => 'python3-aodhclient' }
|
||||
when 'RedHat'
|
||||
{ :client_package_name => 'python-aodhclient' }
|
||||
end
|
||||
|
@ -22,7 +22,7 @@ describe 'aodh::evaluator' do
|
||||
end
|
||||
|
||||
it 'installs python-redis package' do
|
||||
is_expected.to contain_package(platform_params[:redis_package_name]).with(
|
||||
is_expected.to contain_package('python-redis').with(
|
||||
:name => platform_params[:redis_package_name],
|
||||
:tag => 'openstack'
|
||||
)
|
||||
@ -116,7 +116,7 @@ describe 'aodh::evaluator' do
|
||||
when 'Debian'
|
||||
{ :evaluator_package_name => 'aodh-evaluator',
|
||||
:evaluator_service_name => 'aodh-evaluator',
|
||||
:redis_package_name => 'python-redis' }
|
||||
:redis_package_name => 'python3-redis' }
|
||||
when 'RedHat'
|
||||
{ :evaluator_package_name => 'openstack-aodh-evaluator',
|
||||
:evaluator_service_name => 'openstack-aodh-evaluator',
|
||||
|
Loading…
Reference in New Issue
Block a user