forward additional tempest parameters
This commit allows for two additional tempest parameters to be forwarded from the openstack::provision class: * version_to_test * resize_available It also adds some initial and much needed unit tests. Change-Id: I0c352e6f44dc90e055b47db508455972aae2765a
This commit is contained in:
@@ -19,5 +19,7 @@ fixtures:
|
||||
"sysctl": "git://github.com/duritong/puppet-sysctl.git"
|
||||
'inifile': 'git://github.com/cprice-puppet/puppetlabs-inifile'
|
||||
'vswitch': 'git://github.com/bodepd/puppet-vswitch'
|
||||
'tempest': 'git://github.com/stackforge/puppet-tempest'
|
||||
'vcsrepo': 'git://github.com/puppetlabs/puppetlabs-vcsrepo'
|
||||
symlinks:
|
||||
"openstack": "#{source_dir}"
|
||||
|
@@ -69,7 +69,9 @@ class openstack::provision(
|
||||
$identity_uri = undef,
|
||||
$tempest_clone_path = '/var/lib/tempest',
|
||||
$tempest_clone_owner = 'root',
|
||||
$setup_venv = false
|
||||
$setup_venv = false,
|
||||
$version_to_test = 'master',
|
||||
$resize_available = undef
|
||||
) {
|
||||
## Users
|
||||
|
||||
@@ -158,6 +160,7 @@ class openstack::provision(
|
||||
tempest_clone_path => $tempest_clone_path,
|
||||
tempest_clone_owner => $tempest_clone_owner,
|
||||
setup_venv => $setup_venv,
|
||||
version_to_test => $version_to_test,
|
||||
image_name => $image_name,
|
||||
image_name_alt => $image_name,
|
||||
image_ssh_user => $image_ssh_user,
|
||||
@@ -174,6 +177,7 @@ class openstack::provision(
|
||||
admin_tenant_name => $admin_tenant_name,
|
||||
quantum_available => true,
|
||||
public_network_name => $public_network_name,
|
||||
resize_available => $resize_available,
|
||||
require => [
|
||||
Keystone_user[$username],
|
||||
Keystone_user[$alt_username],
|
||||
|
27
spec/classes/openstack_provision_spec.rb
Normal file
27
spec/classes/openstack_provision_spec.rb
Normal file
@@ -0,0 +1,27 @@
|
||||
require 'spec_helper'
|
||||
|
||||
describe 'openstack::provision' do
|
||||
|
||||
let :facts do
|
||||
{
|
||||
:osfamily => 'Debian'
|
||||
}
|
||||
end
|
||||
|
||||
describe 'should be possible to override resize_available' do
|
||||
let :params do
|
||||
{
|
||||
:configure_tempest => true,
|
||||
:resize_available => true,
|
||||
:version_to_test => 'stable/grizzly'
|
||||
}
|
||||
end
|
||||
|
||||
it { should contain_class('tempest').with(
|
||||
:resize_available => true,
|
||||
:version_to_test => 'stable/grizzly'
|
||||
) }
|
||||
|
||||
end
|
||||
|
||||
end
|
Reference in New Issue
Block a user