Merge "Remove redundantly tested code"

This commit is contained in:
Zuul 2019-01-22 02:21:11 +00:00 committed by Gerrit Code Review
commit 6c4fa4facf
1 changed files with 0 additions and 54 deletions

View File

@ -14,7 +14,6 @@ describe 'neutron::db' do
:max_overflow => '<SERVICE DEFAULT>',
:pool_timeout => '<SERVICE DEFAULT>',
)}
end
context 'with specific parameters' do
@ -43,55 +42,6 @@ describe 'neutron::db' do
:max_overflow => '21',
:pool_timeout => '21',
)}
end
context 'with MySQL-python library as backend package' do
let :params do
{ :database_connection => 'mysql+pymysql://neutron:neutron@localhost/neutron' }
end
it { should contain_oslo__db('neutron_config').with(
:connection => 'mysql+pymysql://neutron:neutron@localhost/neutron',
)}
end
context 'with postgresql backend' do
let :params do
{ :database_connection => 'postgresql://neutron:neutron@localhost/neutron', }
end
it 'install the proper backend package' do
should contain_package('python-psycopg2').with(:ensure => 'present')
end
end
context 'with incorrect database_connection string' do
let :params do
{ :database_connection => 'redis://neutron:neutron@localhost/neutron', }
end
it { should raise_error(Puppet::Error, /validate_re/) }
end
context 'with incorrect database_connection string' do
let :params do
{ :database_connection => 'foo+pymysql://neutron:neutron@localhost/neutron', }
end
it { should raise_error(Puppet::Error, /validate_re/) }
end
end
shared_examples 'neutron::db on Debian' do
context 'using pymysql driver' do
let :params do
{ :database_connection => 'mysql+pymysql://neutron:neutron@localhost/neutron' }
end
it { should contain_package('python-pymysql').with({ :ensure => 'present', :name => 'python-pymysql' }) }
end
end
@ -104,10 +54,6 @@ describe 'neutron::db' do
end
it_behaves_like 'neutron::db'
if facts[:osfamily] == 'Debian'
it_behaves_like 'neutron::db on Debian'
end
end
end
end