From eac69736f75240b41992e0cffd3accbb65867006 Mon Sep 17 00:00:00 2001 From: Emilien Macchi Date: Sat, 28 Dec 2013 17:02:59 +0100 Subject: [PATCH] Improve Horizon unit tests It still miss a test for exported ressource (haproxy) Signed-off-by: Emilien Macchi --- spec/classes/dashboard_spec.rb | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) diff --git a/spec/classes/dashboard_spec.rb b/spec/classes/dashboard_spec.rb index db1700cd..dd461737 100644 --- a/spec/classes/dashboard_spec.rb +++ b/spec/classes/dashboard_spec.rb @@ -23,22 +23,28 @@ describe 'privatecloud::dashboard' do shared_examples_for 'openstack dashboard' do let :params do - { :listen_ssl => false, - :secret_key => '/etc/ssl/secret' } + { :listen_ssl => false, + :ks_keystone_internal_host => 'localhost', + :ks_keystone_internal_host => 'localhost', + :secret_key => '/etc/ssl/secret' } end - it 'configure horizon' do - should contain_class('horizon').with( - :listen_ssl => false, - :secret_key => '/etc/ssl/secret' + it 'configure horizon with some params' do + should contain_class('horizon').with( + :listen_ssl => false, + :secret_key => '/etc/ssl/secret', + :keystone_host => 'localhost', + :can_set_mount_point => 'False', + :fqdn => '10.0.0.1,' ) end end context 'on Debian platforms' do let :facts do - { :osfamily => 'Debian', + { :osfamily => 'Debian', :operatingsystemrelease => '12.04', + :ipaddress_eth0 => '10.0.0.1', :concat_basedir => '/var/lib/puppet/concat' } end