memcached (openstack) is no longer in use
[mirror/dsa-puppet.git] / 3rdparty / modules / cinder / spec / classes / cinder_qpid_spec.rb
1 require 'spec_helper'
2
3 describe 'cinder::qpid' do
4
5   let :facts do
6     {:puppetversion => '2.7',
7      :osfamily => 'RedHat'}
8   end
9
10   describe 'with defaults' do
11
12     it 'should contain all of the default resources' do
13
14       should contain_class('qpid::server').with(
15         :service_ensure    => 'running',
16         :port              => '5672'
17       )
18
19     end
20
21     it 'should contain user' do
22
23       should contain_qpid_user('guest').with(
24         :password => 'guest',
25         :file     => '/var/lib/qpidd/qpidd.sasldb',
26         :realm    => 'OPENSTACK',
27         :provider => 'saslpasswd2'
28       )
29
30     end
31
32   end
33
34   describe 'when disabled' do
35     let :params do
36       {
37         :enabled  => false
38       }
39     end
40
41     it 'should be disabled' do
42
43       should_not contain_qpid_user('guest')
44       should contain_class('qpid::server').with(
45         :service_ensure    => 'stopped'
46       )
47
48     end
49   end
50
51 end