3 describe 'nova::compute::vmware' do
6 {:host_ip => '127.0.0.1',
7 :host_username => 'root',
8 :host_password => 'passw0rd',
9 :cluster_name => 'cluster1'}
12 let :optional_params do
13 {:api_retry_count => 10,
14 :maximum_objects => 100,
15 :task_poll_interval => 10.5,
16 :use_linked_clone => false,
17 :wsdl_location => 'http://127.0.0.1:8080/vmware/SDK/wsdl/vim25/vimService.wsdl'}
20 it 'configures vmwareapi in nova.conf' do
21 should contain_nova_config('DEFAULT/compute_driver').with_value('vmwareapi.VMwareVCDriver')
22 should contain_nova_config('VMWARE/host_ip').with_value(params[:host_ip])
23 should contain_nova_config('VMWARE/host_username').with_value(params[:host_username])
24 should contain_nova_config('VMWARE/host_password').with_value(params[:host_password])
25 should contain_nova_config('VMWARE/cluster_name').with_value(params[:cluster_name])
26 should contain_nova_config('VMWARE/api_retry_count').with_value(5)
27 should contain_nova_config('VMWARE/maximum_objects').with_value(100)
28 should contain_nova_config('VMWARE/task_poll_interval').with_value(5.0)
29 should contain_nova_config('VMWARE/use_linked_clone').with_value(true)
30 should_not contain_nova_config('VMWARE/wsdl_location')
33 it 'installs suds python package' do
34 should contain_package('python-suds').with(
39 context 'with optional parameters' do
41 params.merge!(optional_params)
44 it 'configures vmwareapi in nova.conf' do
45 should contain_nova_config('VMWARE/api_retry_count').with_value(params[:api_retry_count])
46 should contain_nova_config('VMWARE/maximum_objects').with_value(params[:maximum_objects])
47 should contain_nova_config('VMWARE/task_poll_interval').with_value(params[:task_poll_interval])
48 should contain_nova_config('VMWARE/use_linked_clone').with_value(false)
49 should contain_nova_config('VMWARE/wsdl_location').with_value(params[:wsdl_location])