Merge "Add test coverage for keystone::db::mysql"
This commit is contained in:
commit
4c6bd18b6a
@ -15,18 +15,18 @@ describe 'keystone::db::mysql' do
|
|||||||
|
|
||||||
let :params do
|
let :params do
|
||||||
{
|
{
|
||||||
'password' => 'keystone_default_password',
|
:password => 'keystone_default_password',
|
||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
|
||||||
describe 'with only required params' do
|
describe 'with only required params' do
|
||||||
it { is_expected.to contain_openstacklib__db__mysql('keystone').with(
|
it { is_expected.to contain_openstacklib__db__mysql('keystone').with(
|
||||||
'user' => 'keystone',
|
:user => 'keystone',
|
||||||
'password_hash' => '*B552157B14BCEDDCEAA06767A012F31BDAA9CE3D',
|
:password_hash => '*B552157B14BCEDDCEAA06767A012F31BDAA9CE3D',
|
||||||
'dbname' => 'keystone',
|
:dbname => 'keystone',
|
||||||
'host' => '127.0.0.1',
|
:host => '127.0.0.1',
|
||||||
'charset' => 'utf8',
|
:charset => 'utf8',
|
||||||
:collate => 'utf8_general_ci',
|
:collate => 'utf8_general_ci',
|
||||||
)}
|
)}
|
||||||
end
|
end
|
||||||
|
|
||||||
@ -38,6 +38,16 @@ describe 'keystone::db::mysql' do
|
|||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
|
||||||
|
it { is_expected.to contain_openstacklib__db__mysql('keystone').with(
|
||||||
|
:user => 'keystone',
|
||||||
|
:password_hash => '*706BFA85E15D0C1D8467D0D81D784F6A04CE4ABB',
|
||||||
|
:dbname => 'keystone',
|
||||||
|
:host => '127.0.0.1',
|
||||||
|
:charset => 'utf8',
|
||||||
|
:collate => 'utf8_general_ci',
|
||||||
|
:allowed_hosts => ['127.0.0.1','%'],
|
||||||
|
)}
|
||||||
|
|
||||||
end
|
end
|
||||||
describe "overriding allowed_hosts param to string" do
|
describe "overriding allowed_hosts param to string" do
|
||||||
let :params do
|
let :params do
|
||||||
@ -47,6 +57,16 @@ describe 'keystone::db::mysql' do
|
|||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
|
||||||
|
it { is_expected.to contain_openstacklib__db__mysql('keystone').with(
|
||||||
|
:user => 'keystone',
|
||||||
|
:password_hash => '*47651CDAAB340A79CC838378072877FFFBF0B239',
|
||||||
|
:dbname => 'keystone',
|
||||||
|
:host => '127.0.0.1',
|
||||||
|
:charset => 'utf8',
|
||||||
|
:collate => 'utf8_general_ci',
|
||||||
|
:allowed_hosts => '192.168.1.1',
|
||||||
|
)}
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|
||||||
describe "overriding allowed_hosts param equals to host param " do
|
describe "overriding allowed_hosts param equals to host param " do
|
||||||
@ -57,6 +77,16 @@ describe 'keystone::db::mysql' do
|
|||||||
}
|
}
|
||||||
end
|
end
|
||||||
|
|
||||||
|
it { is_expected.to contain_openstacklib__db__mysql('keystone').with(
|
||||||
|
:user => 'keystone',
|
||||||
|
:password_hash => '*47651CDAAB340A79CC838378072877FFFBF0B239',
|
||||||
|
:dbname => 'keystone',
|
||||||
|
:host => '127.0.0.1',
|
||||||
|
:charset => 'utf8',
|
||||||
|
:collate => 'utf8_general_ci',
|
||||||
|
:allowed_hosts => '127.0.0.1',
|
||||||
|
)}
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
|
Loading…
Reference in New Issue
Block a user