]> git.donarmstrong.com Git - dsa-puppet.git/blob - 3rdparty/modules/nova/spec/classes/nova_compute_xenserver_spec.rb
try again, with puppetforge modules, correctly included now
[dsa-puppet.git] / 3rdparty / modules / nova / spec / classes / nova_compute_xenserver_spec.rb
1 require 'spec_helper'
2
3 describe 'nova::compute::xenserver' do
4
5   let :params do
6     { :xenapi_connection_url      => 'https://127.0.0.1',
7       :xenapi_connection_username => 'root',
8       :xenapi_connection_password => 'passw0rd' }
9   end
10
11   context 'with required parameters' do
12
13     it 'configures xenapi in nova.conf' do
14       should contain_nova_config('DEFAULT/compute_driver').with_value('xenapi.XenAPIDriver')
15       should contain_nova_config('DEFAULT/connection_type').with_value('xenapi')
16       should contain_nova_config('DEFAULT/xenapi_connection_url').with_value(params[:xenapi_connection_url])
17       should contain_nova_config('DEFAULT/xenapi_connection_username').with_value(params[:xenapi_connection_username])
18       should contain_nova_config('DEFAULT/xenapi_connection_password').with_value(params[:xenapi_connection_password])
19       should contain_nova_config('DEFAULT/xenapi_inject_image').with_value(false)
20     end
21
22     it 'installs xenapi with pip' do
23       should contain_package('xenapi').with(
24         :ensure   => 'present',
25         :provider => 'pip'
26       )
27     end
28   end
29 end