puppet-panko/spec/classes/panko_db_postgresql_spec.rb
Emilien Macchi 11ad261fa9 puppet-panko: Initial commit
This is the initial commit for puppet-panko.
It has been automatically generated using cookiecutter[1] and msync[2]

[1] https://github.com/openstack/puppet-openstack-cookiecutter
[2] https://github.com/openstack/puppet-modulesync-configs

Change-Id: I7098c08fe22d8cdc7f3635c2b1ae4e1e28dc8cd1
2016-08-25 11:30:54 -04:00

38 lines
824 B
Ruby

require 'spec_helper'
describe 'panko::db::postgresql' do
let :pre_condition do
'include postgresql::server'
end
let :required_params do
{ :password => 'pw' }
end
shared_examples_for 'panko-db-postgresql' do
context 'with only required parameters' do
let :params do
required_params
end
it { is_expected.to contain_postgresql__server__db('panko').with(
:user => 'panko',
:password => 'md558cac1b05100d25689b06310945fc3b4'
)}
end
end
on_supported_os({
:supported_os => OSDefaults.get_supported_os
}).each do |os,facts|
context "on #{os}" do
let (:facts) do
facts.merge!(OSDefaults.get_facts({ :concat_basedir => '/var/lib/puppet/concat' }))
end
it_behaves_like 'panko-db-postgresql'
end
end
end