Browse Source

Merge "Use anchor to require necessary packages/services"

changes/74/726674/1
Zuul 2 years ago
committed by Gerrit Code Review
parent
commit
760e9f9b27
  1. 4
      lib/puppet/type/eswitchd_config.rb
  2. 4
      lib/puppet/type/ironic_neutron_agent_config.rb
  3. 4
      lib/puppet/type/neutron_agent_linuxbridge.rb
  4. 4
      lib/puppet/type/neutron_agent_ovs.rb
  5. 4
      lib/puppet/type/neutron_agent_vpp.rb
  6. 4
      lib/puppet/type/neutron_api_paste_ini.rb
  7. 4
      lib/puppet/type/neutron_bgp_dragent_config.rb
  8. 4
      lib/puppet/type/neutron_bgpvpn_bagpipe_config.rb
  9. 4
      lib/puppet/type/neutron_bgpvpn_service_config.rb
  10. 4
      lib/puppet/type/neutron_config.rb
  11. 4
      lib/puppet/type/neutron_dhcp_agent_config.rb
  12. 4
      lib/puppet/type/neutron_fwaas_service_config.rb
  13. 6
      lib/puppet/type/neutron_l2gw_agent_config.rb
  14. 4
      lib/puppet/type/neutron_l2gw_service_config.rb
  15. 4
      lib/puppet/type/neutron_l3_agent_config.rb
  16. 4
      lib/puppet/type/neutron_l3_ovs_bridge.rb
  17. 4
      lib/puppet/type/neutron_metadata_agent_config.rb
  18. 4
      lib/puppet/type/neutron_metering_agent_config.rb
  19. 4
      lib/puppet/type/neutron_mlnx_agent_config.rb
  20. 4
      lib/puppet/type/neutron_network.rb
  21. 4
      lib/puppet/type/neutron_plugin_cisco.rb
  22. 4
      lib/puppet/type/neutron_plugin_cisco_credentials.rb
  23. 4
      lib/puppet/type/neutron_plugin_cisco_db_conn.rb
  24. 4
      lib/puppet/type/neutron_plugin_cisco_l2network.rb
  25. 6
      lib/puppet/type/neutron_plugin_midonet.rb
  26. 4
      lib/puppet/type/neutron_plugin_ml2.rb
  27. 4
      lib/puppet/type/neutron_plugin_nsx.rb
  28. 4
      lib/puppet/type/neutron_plugin_nuage.rb
  29. 4
      lib/puppet/type/neutron_plugin_nvp.rb
  30. 4
      lib/puppet/type/neutron_plugin_opencontrail.rb
  31. 4
      lib/puppet/type/neutron_plugin_plumgrid.rb
  32. 4
      lib/puppet/type/neutron_plugin_sriov.rb
  33. 4
      lib/puppet/type/neutron_plumlib_plumgrid.rb
  34. 4
      lib/puppet/type/neutron_port.rb
  35. 4
      lib/puppet/type/neutron_rootwrap_config.rb
  36. 4
      lib/puppet/type/neutron_router.rb
  37. 4
      lib/puppet/type/neutron_router_interface.rb
  38. 4
      lib/puppet/type/neutron_security_group.rb
  39. 4
      lib/puppet/type/neutron_sfc_service_config.rb
  40. 4
      lib/puppet/type/neutron_sriov_agent_config.rb
  41. 4
      lib/puppet/type/neutron_subnet.rb
  42. 4
      lib/puppet/type/neutron_vpnaas_agent_config.rb
  43. 4
      lib/puppet/type/neutron_vpnaas_service_config.rb
  44. 4
      lib/puppet/type/ovn_metadata_agent_config.rb
  45. 2
      manifests/agents/bigswitch.pp
  46. 2
      manifests/plugins/midonet.pp
  47. 2
      manifests/plugins/ml2.pp
  48. 2
      manifests/plugins/nvp.pp
  49. 2
      manifests/plugins/opencontrail.pp
  50. 6
      manifests/services/fwaas.pp
  51. 2
      manifests/services/l2gw.pp
  52. 2
      spec/classes/neutron_agents_bigswitch.rb
  53. 4
      spec/classes/neutron_plugins_ml2_spec.rb
  54. 2
      spec/classes/neutron_plugins_nvp_spec.rb
  55. 6
      spec/classes/neutron_services_fwaas_spec.rb
  56. 6
      spec/unit/type/ironic_neutron_agent_config_spec.rb
  57. 6
      spec/unit/type/neutron_agent_linuxbridge_spec.rb
  58. 6
      spec/unit/type/neutron_agent_ovs_spec.rb
  59. 6
      spec/unit/type/neutron_agent_vpp_spec.rb
  60. 6
      spec/unit/type/neutron_api_paste_ini_spec.rb
  61. 11
      spec/unit/type/neutron_bgp_dragent_config_spec.rb
  62. 6
      spec/unit/type/neutron_bgpvpn_bagpipe_config_spec.rb
  63. 6
      spec/unit/type/neutron_bgpvpn_service_config_spec.rb
  64. 6
      spec/unit/type/neutron_config_spec.rb
  65. 6
      spec/unit/type/neutron_dhcp_agent_config_spec.rb
  66. 6
      spec/unit/type/neutron_fwaas_service_config_spec.rb
  67. 6
      spec/unit/type/neutron_l2gw_agent_config_spec.rb
  68. 6
      spec/unit/type/neutron_l2gw_service_config_spec.rb
  69. 6
      spec/unit/type/neutron_l3_agent_config_spec.rb
  70. 6
      spec/unit/type/neutron_metadata_agent_config_spec.rb
  71. 11
      spec/unit/type/neutron_metering_agent_config_spec.rb
  72. 6
      spec/unit/type/neutron_plugin_cisco_credentials_spec.rb
  73. 6
      spec/unit/type/neutron_plugin_cisco_db_conn_spec.rb
  74. 6
      spec/unit/type/neutron_plugin_cisco_l2network_spec.rb
  75. 6
      spec/unit/type/neutron_plugin_cisco_spec.rb
  76. 6
      spec/unit/type/neutron_plugin_midonet_spec.rb
  77. 6
      spec/unit/type/neutron_plugin_ml2_spec.rb
  78. 6
      spec/unit/type/neutron_plugin_nsx_spec.rb
  79. 6
      spec/unit/type/neutron_plugin_nvp_spec.rb
  80. 6
      spec/unit/type/neutron_plugin_opencontrail_spec.rb
  81. 6
      spec/unit/type/neutron_plugin_plumgrid_spec.rb
  82. 6
      spec/unit/type/neutron_plumlib_plumgrid_spec.rb
  83. 6
      spec/unit/type/neutron_rootwrap_config_spec.rb
  84. 6
      spec/unit/type/neutron_sfc_service_config_spec.rb
  85. 11
      spec/unit/type/neutron_vpnaas_agent_config_spec.rb
  86. 6
      spec/unit/type/ovn_metadata_agent_config_spec.rb

4
lib/puppet/type/eswitchd_config.rb

@ -12,7 +12,9 @@ Puppet::Type.newtype(:eswitchd_config) do
defaultto('<SERVICE DEFAULT>')
end
autorequire(:package) do ['neutron'] end
autorequire(:anchor) do
['neutron::install::end']
end
newproperty(:value) do
desc 'The value of the setting to be defined.'

4
lib/puppet/type/ironic_neutron_agent_config.rb

@ -21,8 +21,8 @@ Puppet::Type.newtype(:ironic_neutron_agent_config) do
defaultto('<SERVICE DEFAULT>')
end
autorequire(:package) do
'python2-ironic-neutron-agent'
autorequire(:anchor) do
['neutron::install::end']
end
end

4
lib/puppet/type/neutron_agent_linuxbridge.rb

@ -21,8 +21,8 @@ Puppet::Type.newtype(:neutron_agent_linuxbridge) do
defaultto('<SERVICE DEFAULT>')
end
autorequire(:package) do
'neutron-plugin-linuxbridge-agent'
autorequire(:anchor) do
['neutron::install::end']
end
end

4
lib/puppet/type/neutron_agent_ovs.rb

@ -21,8 +21,8 @@ Puppet::Type.newtype(:neutron_agent_ovs) do
defaultto('<SERVICE DEFAULT>')
end
autorequire(:package) do
'neutron-ovs-agent'
autorequire(:anchor) do
['neutron::install::end']
end
end

4
lib/puppet/type/neutron_agent_vpp.rb

@ -21,8 +21,8 @@ Puppet::Type.newtype(:neutron_agent_vpp) do
defaultto('<SERVICE DEFAULT>')
end
autorequire(:package) do
'neutron-vpp-agent'
autorequire(:anchor) do
['neutron::install::end']
end
end

4
lib/puppet/type/neutron_api_paste_ini.rb

@ -45,8 +45,8 @@ Puppet::Type.newtype(:neutron_api_paste_ini) do
defaultto('<SERVICE DEFAULT>')
end
autorequire(:package) do
'neutron'
autorequire(:anchor) do
['neutron::install::end']
end
end

4
lib/puppet/type/neutron_bgp_dragent_config.rb

@ -21,8 +21,8 @@ Puppet::Type.newtype(:neutron_bgp_dragent_config) do
defaultto('<SERVICE DEFAULT>')
end
autorequire(:package) do
['neutron-dynamic-routing', 'neutron-bgp-dragent']
autorequire(:anchor) do
['neutron::install::end']
end
end

4
lib/puppet/type/neutron_bgpvpn_bagpipe_config.rb

@ -21,8 +21,8 @@ Puppet::Type.newtype(:neutron_bgpvpn_bagpipe_config) do
defaultto('<SERVICE DEFAULT>')
end
autorequire(:package) do
['openstack-bagpipe-bgp']
autorequire(:anchor) do
['neutron::install::end']
end
end

4
lib/puppet/type/neutron_bgpvpn_service_config.rb

@ -31,6 +31,8 @@ Puppet::Type.newtype(:neutron_bgpvpn_service_config) do
defaultto('<SERVICE DEFAULT>')
end
autorequire(:package) do ['python-networking-bgpvpn'] end
autorequire(:anchor) do
['neutron::install::end']
end
end

4
lib/puppet/type/neutron_config.rb

@ -61,8 +61,8 @@ Puppet::Type.newtype(:neutron_config) do
provider.create
end
autorequire(:package) do
'neutron'
autorequire(:anchor) do
['neutron::install::end']
end
end

4
lib/puppet/type/neutron_dhcp_agent_config.rb

@ -21,8 +21,8 @@ Puppet::Type.newtype(:neutron_dhcp_agent_config) do
defaultto('<SERVICE DEFAULT>')
end
autorequire(:package) do
'neutron'
autorequire(:anchor) do
['neutron::install::end']
end
end

4
lib/puppet/type/neutron_fwaas_service_config.rb

@ -21,8 +21,8 @@ Puppet::Type.newtype(:neutron_fwaas_service_config) do
defaultto('<SERVICE DEFAULT>')
end
autorequire(:package) do
'neutron-fwaas'
autorequire(:anchor) do
['neutron::install::end']
end
end

6
lib/puppet/type/neutron_l2gw_agent_config.rb

@ -21,8 +21,8 @@ Puppet::Type.newtype(:neutron_l2gw_agent_config) do
defaultto('<SERVICE DEFAULT>')
end
autorequire(:package) do
['neutron-l2gw-agent']
autorequire(:anchor) do
['neutron::install::end']
end
end
end

4
lib/puppet/type/neutron_l2gw_service_config.rb

@ -31,8 +31,8 @@ Puppet::Type.newtype(:neutron_l2gw_service_config) do
defaultto('<SERVICE DEFAULT>')
end
autorequire(:package) do
['python-networking-l2gw']
autorequire(:anchor) do
['neutron::install::end']
end
end

4
lib/puppet/type/neutron_l3_agent_config.rb

@ -23,8 +23,8 @@ Puppet::Type.newtype(:neutron_l3_agent_config) do
newparam(:transform_to)
autorequire(:package) do
'neutron'
autorequire(:anchor) do
['neutron::install::end']
end
end

4
lib/puppet/type/neutron_l3_ovs_bridge.rb

@ -11,8 +11,8 @@ Puppet::Type.newtype(:neutron_l3_ovs_bridge) do
desc 'Name of the subnet that will use the bridge as gateway'
end
autorequire(:service) do
['neutron-server']
autorequire(:anchor) do
['neutron::service::end']
end
autorequire(:vs_bridge) do

4
lib/puppet/type/neutron_metadata_agent_config.rb

@ -45,8 +45,8 @@ Puppet::Type.newtype(:neutron_metadata_agent_config) do
defaultto('<SERVICE DEFAULT>')
end
autorequire(:package) do
'neutron'
autorequire(:anchor) do
['neutron::install::end']
end
end

4
lib/puppet/type/neutron_metering_agent_config.rb

@ -21,8 +21,8 @@ Puppet::Type.newtype(:neutron_metering_agent_config) do
defaultto('<SERVICE DEFAULT>')
end
autorequire(:package) do
['neutron', 'neutron-metering-agent']
autorequire(:anchor) do
['neutron::install::end']
end
end

4
lib/puppet/type/neutron_mlnx_agent_config.rb

@ -12,7 +12,9 @@ Puppet::Type.newtype(:neutron_mlnx_agent_config) do
defaultto('<SERVICE DEFAULT>')
end
autorequire(:package) do ['neutron'] end
autorequire(:anchor) do
['neutron::install::end']
end
newproperty(:value) do
desc 'The value of the setting to be defined.'

4
lib/puppet/type/neutron_network.rb

@ -74,8 +74,8 @@ Puppet::Type.newtype(:neutron_network) do
end
# Require the neutron-server service to be running
autorequire(:service) do
['neutron-server']
autorequire(:anchor) do
['neutron::service::end']
end
autorequire(:keystone_tenant) do

4
lib/puppet/type/neutron_plugin_cisco.rb

@ -49,8 +49,8 @@ Puppet::Type.newtype(:neutron_plugin_cisco) do
['/etc/neutron/plugins/cisco']
end
autorequire(:package) do
'neutron-plugin-cisco'
autorequire(:anchor) do
['neutron::install::end']
end
end

4
lib/puppet/type/neutron_plugin_cisco_credentials.rb

@ -50,8 +50,8 @@ Puppet::Type.newtype(:neutron_plugin_cisco_credentials) do
['/etc/neutron/plugins/cisco']
end
autorequire(:package) do
'neutron-plugin-cisco'
autorequire(:anchor) do
['neutron::install::end']
end
end

4
lib/puppet/type/neutron_plugin_cisco_db_conn.rb

@ -25,8 +25,8 @@ Puppet::Type.newtype(:neutron_plugin_cisco_db_conn) do
['/etc/neutron/plugins/cisco']
end
autorequire(:package) do
'neutron-plugin-cisco'
autorequire(:anchor) do
['neutron::install::end']
end
end

4
lib/puppet/type/neutron_plugin_cisco_l2network.rb

@ -25,8 +25,8 @@ Puppet::Type.newtype(:neutron_plugin_cisco_l2network) do
['/etc/neutron/plugins/cisco']
end
autorequire(:package) do
'neutron-plugin-cisco'
autorequire(:anchor) do
['neutron::install::end']
end
end

6
lib/puppet/type/neutron_plugin_midonet.rb

@ -7,8 +7,6 @@ Puppet::Type.newtype(:neutron_plugin_midonet) do
newvalues(/\S+\/\S+/)
end
autorequire(:package) do ['neutron'] end
newproperty(:value) do
desc 'The value of the setting to be defined.'
munge do |value|
@ -51,8 +49,8 @@ Puppet::Type.newtype(:neutron_plugin_midonet) do
['/etc/neutron/plugins/midonet']
end
autorequire(:package) do
'python-networking-midonet'
autorequire(:anchor) do
['neutron::install::end']
end
end

4
lib/puppet/type/neutron_plugin_ml2.rb

@ -43,8 +43,8 @@ Puppet::Type.newtype(:neutron_plugin_ml2) do
defaultto('<SERVICE DEFAULT>')
end
autorequire(:package) do
['neutron', 'neutron-plugin-ml2']
autorequire(:anchor) do
['neutron::install::end']
end
end

4
lib/puppet/type/neutron_plugin_nsx.rb

@ -49,8 +49,8 @@ Puppet::Type.newtype(:neutron_plugin_nsx) do
'/etc/neutron/plugins/vmware'
end
autorequire(:package) do
'vmware-nsx'
autorequire(:anchor) do
['neutron::install::end']
end
end

4
lib/puppet/type/neutron_plugin_nuage.rb

@ -21,8 +21,8 @@ Puppet::Type.newtype(:neutron_plugin_nuage) do
defaultto('<SERVICE DEFAULT>')
end
autorequire(:package) do
'neutron-plugin-nuage'
autorequire(:anchor) do
['neutron::install::end']
end
autorequire(:file) do

4
lib/puppet/type/neutron_plugin_nvp.rb

@ -45,8 +45,8 @@ Puppet::Type.newtype(:neutron_plugin_nvp) do
defaultto('<SERVICE DEFAULT>')
end
autorequire(:package) do
'neutron-plugin-nvp'
autorequire(:anchor) do
['neutron::install::end']
end
end

4
lib/puppet/type/neutron_plugin_opencontrail.rb

@ -49,8 +49,8 @@ Puppet::Type.newtype(:neutron_plugin_opencontrail) do
['/etc/neutron/plugins/opencontrail']
end
autorequire(:package) do
'neutron-plugin-opencontrail'
autorequire(:anchor) do
['neutron::install::end']
end
end

4
lib/puppet/type/neutron_plugin_plumgrid.rb

@ -49,8 +49,8 @@ Puppet::Type.newtype(:neutron_plugin_plumgrid) do
['/etc/neutron/plugins/plumgrid']
end
autorequire(:package) do
'neutron-plugin-plumgrid'
autorequire(:anchor) do
['neutron::install::end']
end
end

4
lib/puppet/type/neutron_plugin_sriov.rb

@ -12,7 +12,9 @@ Puppet::Type.newtype(:neutron_plugin_sriov) do
defaultto('<SERVICE DEFAULT>')
end
autorequire(:package) do ['neutron'] end
autorequire(:anchor) do
['neutron::install::end']
end
newproperty(:value) do
desc 'The value of the setting to be defined.'

4
lib/puppet/type/neutron_plumlib_plumgrid.rb

@ -49,8 +49,8 @@ Puppet::Type.newtype(:neutron_plumlib_plumgrid) do
['/etc/neutron/plugins/plumgrid']
end
autorequire(:package) do
'neutron-plumlib-plumgrid'
autorequire(:anchor) do
['neutron::install::end']
end
end

4
lib/puppet/type/neutron_port.rb

@ -88,8 +88,8 @@ Puppet::Type.newtype(:neutron_port) do
end
end
autorequire(:service) do
['neutron-server']
autorequire(:anchor) do
['neutron::service::end']
end
autorequire(:keystone_tenant) do

4
lib/puppet/type/neutron_rootwrap_config.rb

@ -21,8 +21,8 @@ Puppet::Type.newtype(:neutron_rootwrap_config) do
defaultto('<SERVICE DEFAULT>')
end
autorequire(:package) do
'neutron-common'
autorequire(:anchor) do
['neutron::install::end']
end
end

4
lib/puppet/type/neutron_router.rb

@ -64,8 +64,8 @@ Puppet::Type.newtype(:neutron_router) do
desc 'A uuid identifying the tenant which will own the router.'
end
autorequire(:service) do
['neutron-server']
autorequire(:anchor) do
['neutron::service::end']
end
autorequire(:keystone_tenant) do

4
lib/puppet/type/neutron_router_interface.rb

@ -44,8 +44,8 @@ Puppet::Type.newtype(:neutron_router_interface) do
desc 'An existing neutron port to which a router interface should be assigned'
end
autorequire(:service) do
['neutron-server']
autorequire(:anchor) do
['neutron::service::end']
end
autorequire(:neutron_router) do

4
lib/puppet/type/neutron_security_group.rb

@ -34,8 +34,8 @@ Puppet::Type.newtype(:neutron_security_group) do
end
# Require the neutron-server service to be running
autorequire(:service) do
['neutron-server']
autorequire(:anchor) do
['neutron::service::end']
end
newparam(:name, :namevar => true) do

4
lib/puppet/type/neutron_sfc_service_config.rb

@ -31,6 +31,8 @@ Puppet::Type.newtype(:neutron_sfc_service_config) do
defaultto('<SERVICE DEFAULT>')
end
autorequire(:package) do ['python-networking-sfc'] end
autorequire(:anchor) do
['neutron::install::end']
end
end

4
lib/puppet/type/neutron_sriov_agent_config.rb

@ -12,7 +12,9 @@ Puppet::Type.newtype(:neutron_sriov_agent_config) do
defaultto('<SERVICE DEFAULT>')
end
autorequire(:package) do ['neutron'] end
autorequire(:anchor) do
['neutron::install::end']
end
newproperty(:value) do
desc 'The value of the setting to be defined.'

4
lib/puppet/type/neutron_subnet.rb

@ -88,8 +88,8 @@ Puppet::Type.newtype(:neutron_subnet) do
desc 'A uuid identifying the tenant which will own the subnet.'
end
autorequire(:service) do
['neutron-server']
autorequire(:anchor) do
['neutron::service::end']
end
autorequire(:keystone_tenant) do

4
lib/puppet/type/neutron_vpnaas_agent_config.rb

@ -21,8 +21,8 @@ Puppet::Type.newtype(:neutron_vpnaas_agent_config) do
defaultto('<SERVICE DEFAULT>')
end
autorequire(:package) do
['neutron', 'neutron-vpnaas-agent']
autorequire(:anchor) do
['neutron::install::end']
end
end

4
lib/puppet/type/neutron_vpnaas_service_config.rb

@ -33,8 +33,8 @@ Puppet::Type.newtype(:neutron_vpnaas_service_config) do
defaultto('<SERVICE DEFAULT>')
end
autorequire(:package) do
'neutron-vpnaas-agent'
autorequire(:anchor) do
['neutron::install::end']
end
end

4
lib/puppet/type/ovn_metadata_agent_config.rb

@ -45,8 +45,8 @@ Puppet::Type.newtype(:ovn_metadata_agent_config) do
defaultto('<SERVICE DEFAULT>')
end
autorequire(:package) do
'python-networking-ovn-metadata-agent'
autorequire(:anchor) do
['neutron::install::end']
end
end

2
manifests/agents/bigswitch.pp

@ -33,7 +33,7 @@ class neutron::agents::bigswitch (
ensure_packages("python${neutron::params::pyvers}-networking-bigswitch",
{
ensure => $package_ensure,
tag => 'openstack',
tag => ['openstack', 'neutron-package'],
}
)

2
manifests/plugins/midonet.pp

@ -142,7 +142,7 @@ class neutron::plugins::midonet (
package { 'python-networking-midonet':
ensure => $package_ensure,
name => $::neutron::params::midonet_server_package,
tag => ['neutron-package', 'openstack'],
tag => ['openstack', 'neutron-package'],
}
neutron_plugin_midonet {

2
manifests/plugins/ml2.pp

@ -193,7 +193,7 @@ class neutron::plugins::ml2 (
package { 'neutron-plugin-ml2':
ensure => $package_ensure,
name => $::neutron::params::ml2_server_package,
tag => ['neutron-package', 'openstack'],
tag => ['openstack', 'neutron-package'],
}
}

2
manifests/plugins/nvp.pp

@ -48,7 +48,7 @@ class neutron::plugins::nvp (
package { 'neutron-plugin-nvp':
ensure => $package_ensure,
name => $::neutron::params::nvp_server_package,
tag => ['neutron-package', 'openstack'],
tag => ['openstack', 'neutron-package'],
}
validate_legacy(Array, 'validate_array', $nvp_controllers)

2
manifests/plugins/opencontrail.pp

@ -74,7 +74,7 @@ class neutron::plugins::opencontrail (
package { 'neutron-plugin-contrail':
ensure => $package_ensure,
name => $::neutron::params::opencontrail_plugin_package,
tag => ['neutron-package', 'openstack'],
tag => ['openstack', 'neutron-package'],
}
ensure_resource('file', '/etc/neutron/plugins/opencontrail', {

6
manifests/services/fwaas.pp

@ -63,14 +63,14 @@ class neutron::services::fwaas (
ensure_resource( 'package', 'neutron-vpn-agent', {
'name' => $::neutron::params::vpnaas_agent_package,
'ensure' => $neutron::package_ensure,
'tag' => ['neutron-package', 'openstack'],
'tag' => ['openstack', 'neutron-package'],
})
}
else {
ensure_resource( 'package', 'neutron-fwaas' , {
'name' => $::neutron::params::fwaas_package,
'ensure' => $neutron::package_ensure,
'tag' => ['neutron-package', 'openstack'],
'tag' => ['openstack', 'neutron-package'],
})
}
} elsif($::osfamily == 'Redhat') {
@ -78,7 +78,7 @@ class neutron::services::fwaas (
ensure_resource( 'package', 'neutron-fwaas', {
'name' => $::neutron::params::fwaas_package,
'ensure' => $neutron::package_ensure,
'tag' => ['neutron-package', 'openstack'],
'tag' => ['openstack', 'neutron-package'],
})
}

2
manifests/services/l2gw.pp

@ -63,7 +63,7 @@ class neutron::services::l2gw (
ensure_resource( 'package', 'python-networking-l2gw', {
'ensure' => $package_ensure,
'name' => $::neutron::params::l2gw_package,
'tag' => ['neutron-package', 'openstack'],
'tag' => ['openstack', 'neutron-package'],
})
resources { 'neutron_l2gw_service_config':

2
spec/classes/neutron_agents_bigswitch.rb

@ -10,7 +10,7 @@ describe 'neutron::agents::bigswitch' do
it 'should have' do
should contain_package('python-networking-bigswitch').with(
:ensure => 'present',
:tag => 'openstack'
:tag => ['openstack', 'neutron-package'],
)
end
end

4
spec/classes/neutron_plugins_ml2_spec.rb

@ -89,7 +89,7 @@ describe 'neutron::plugins::ml2' do
should contain_package('neutron-plugin-ml2').with(
:name => platform_params[:ml2_server_package],
:ensure => p[:package_ensure],
:tag => ['neutron-package', 'openstack'],
:tag => ['openstack', 'neutron-package'],
)
should contain_package('neutron-plugin-ml2').that_requires('Anchor[neutron::install::begin]')
should contain_package('neutron-plugin-ml2').that_notifies('Anchor[neutron::install::end]')
@ -274,7 +274,7 @@ describe 'neutron::plugins::ml2' do
should contain_package('neutron-plugin-ml2').with(
:name => platform_params[:ml2_server_package],
:ensure => params[:package_ensure],
:tag => ['neutron-package', 'openstack'],
:tag => ['openstack', 'neutron-package'],
)
end
end

2
spec/classes/neutron_plugins_nvp_spec.rb

@ -41,7 +41,7 @@ describe 'neutron::plugins::nvp' do
should contain_package('neutron-plugin-nvp').with(
:name => platform_params[:nvp_server_package],
:ensure => p[:package_ensure],
:tag => ['neutron-package', 'openstack'],
:tag => ['openstack', 'neutron-package'],
)
end

6
spec/classes/neutron_services_fwaas_spec.rb

@ -65,7 +65,7 @@ describe 'neutron::services::fwaas' do
it 'installs neutron fwaas package' do
should contain_package('neutron-fwaas').with(
:ensure => 'present',
:tag => ['neutron-package', 'openstack'],
:tag => ['openstack', 'neutron-package'],
:name => platform_params[:fwaas_package_name],
)
end
@ -76,7 +76,7 @@ describe 'neutron::services::fwaas' do
it 'installs neutron fwaas package' do
should contain_package('neutron-fwaas').with(
:ensure => 'present',
:tag => ['neutron-package', 'openstack'],
:tag => ['openstack', 'neutron-package'],
:name => platform_params[:fwaas_package_name],
)
end
@ -91,7 +91,7 @@ describe 'neutron::services::fwaas' do
should contain_package('neutron-vpn-agent').with(
:ensure => 'present',
:name => platform_params[:vpnaas_package_name],
:tag => ['neutron-package', 'openstack'],
:tag => ['openstack', 'neutron-package'],
)
end
end

6
spec/unit/type/ironic_neutron_agent_config_spec.rb

@ -9,12 +9,12 @@ describe 'Puppet::Type.type(:ironic_neutron_agent_config)' do
it 'should autorequire the package that install the file' do
catalog = Puppet::Resource::Catalog.new
package = Puppet::Type.type(:package).new(:name => 'python2-ironic-neutron-agent')
catalog.add_resource package, @ironic_neutron_agent_config
anchor = Puppet::Type.type(:anchor).new(:name => 'neutron::install::end')
catalog.add_resource anchor, @ironic_neutron_agent_config
dependency = @ironic_neutron_agent_config.autorequire
expect(dependency.size).to eq(1)
expect(dependency[0].target).to eq(@ironic_neutron_agent_config)
expect(dependency[0].source).to eq(package)
expect(dependency[0].source).to eq(anchor)
end
end

6
spec/unit/type/neutron_agent_linuxbridge_spec.rb

@ -9,12 +9,12 @@ describe 'Puppet::Type.type(:neutron_agent_linuxbridge)' do
it 'should autorequire the package that install the file' do
catalog = Puppet::Resource::Catalog.new
package = Puppet::Type.type(:package).new(:name => 'neutron-plugin-linuxbridge-agent')
catalog.add_resource package, @neutron_agent_linuxbridge
anchor = Puppet::Type.type(:anchor).new(:name => 'neutron::install::end')
catalog.add_resource anchor, @neutron_agent_linuxbridge
dependency = @neutron_agent_linuxbridge.autorequire
expect(dependency.size).to eq(1)
expect(dependency[0].target).to eq(@neutron_agent_linuxbridge)
expect(dependency[0].source).to eq(package)
expect(dependency[0].source).to eq(anchor)
end
end

6
spec/unit/type/neutron_agent_ovs_spec.rb

@ -9,12 +9,12 @@ describe 'Puppet::Type.type(:neutron_agent_ovs)' do
it 'should autorequire the package that install the file' do
catalog = Puppet::Resource::Catalog.new
package = Puppet::Type.type(:package).new(:name => 'neutron-ovs-agent')
catalog.add_resource package, @neutron_agent_ovs
anchor = Puppet::Type.type(:anchor).new(:name => 'neutron::install::end')
catalog.add_resource anchor, @neutron_agent_ovs
dependency = @neutron_agent_ovs.autorequire
expect(dependency.size).to eq(1)
expect(dependency[0].target).to eq(@neutron_agent_ovs)
expect(dependency[0].source).to eq(package)
expect(dependency[0].source).to eq(anchor)
end
end

6
spec/unit/type/neutron_agent_vpp_spec.rb

@ -9,12 +9,12 @@ describe 'Puppet::Type.type(:neutron_agent_vpp)' do
it 'should autorequire the package that install the file' do
catalog = Puppet::Resource::Catalog.new
package = Puppet::Type.type(:package).new(:name => 'neutron-vpp-agent')
catalog.add_resource package, @neutron_agent_vpp
anchor = Puppet::Type.type(:anchor).new(:name => 'neutron::install::end')
catalog.add_resource anchor, @neutron_agent_vpp
dependency = @neutron_agent_vpp.autorequire
expect(dependency.size).to eq(1)
expect(dependency[0].target).to eq(@neutron_agent_vpp)
expect(dependency[0].source).to eq(package)
expect(dependency[0].source).to eq(anchor)
end
end

6
spec/unit/type/neutron_api_paste_ini_spec.rb

@ -23,12 +23,12 @@ describe 'Puppet::Type.type(:neutron_api_paste_ini)' do
it 'should autorequire the package that install the file' do
catalog = Puppet::Resource::Catalog.new
package = Puppet::Type.type(:package).new(:name => 'neutron')
catalog.add_resource package, @neutron_api_paste_ini
anchor = Puppet::Type.type(:anchor).new(:name => 'neutron::install::end')
catalog.add_resource anchor, @neutron_api_paste_ini
dependency = @neutron_api_paste_ini.autorequire
expect(dependency.size).to eq(1)
expect(dependency[0].target).to eq(@neutron_api_paste_ini)
expect(dependency[0].source).to eq(package)
expect(dependency[0].source).to eq(anchor)
end
end

11
spec/unit/type/neutron_bgp_dragent_config_spec.rb

@ -9,15 +9,12 @@ describe 'Puppet::Type.type(:neutron_bgp_dragent_config)' do
it 'should autorequire the package that install the file' do
catalog = Puppet::Resource::Catalog.new
package1 = Puppet::Type.type(:package).new(:name => 'neutron-dynamic-routing')
package2 = Puppet::Type.type(:package).new(:name => 'neutron-bgp-dragent')
catalog.add_resource package1, package2, @neutron_bgp_dragent_config
anchor = Puppet::Type.type(:anchor).new(:name => 'neutron::install::end')
catalog.add_resource anchor, @neutron_bgp_dragent_config
dependency = @neutron_bgp_dragent_config.autorequire
expect(dependency.size).to eq(2)
expect(dependency.size).to eq(1)
expect(dependency[0].target).to eq(@neutron_bgp_dragent_config)
expect(dependency[0].source).to eq(package1)
expect(dependency[1].target).to eq(@neutron_bgp_dragent_config)
expect(dependency[1].source).to eq(package2)
expect(dependency[0].source).to eq(anchor)
end
end

6
spec/unit/type/neutron_bgpvpn_bagpipe_config_spec.rb

@ -9,12 +9,12 @@ describe 'Puppet::Type.type(:neutron_bgpvpn_bagpipe_config)' do
it 'should autorequire the package that install the file' do
catalog = Puppet::Resource::Catalog.new
package = Puppet::Type.type(:package).new(:name => 'openstack-bagpipe-bgp')
catalog.add_resource package, @neutron_bgpvpn_bagpipe_config
anchor = Puppet::Type.type(:anchor).new(:name => 'neutron::install::end')
catalog.add_resource anchor, @neutron_bgpvpn_bagpipe_config
dependency = @neutron_bgpvpn_bagpipe_config.autorequire
expect(dependency.size).to eq(1)
expect(dependency[0].target).to eq(@neutron_bgpvpn_bagpipe_config)
expect(dependency[0].source).to eq(package)
expect(dependency[0].source).to eq(anchor)
end
end

6
spec/unit/type/neutron_bgpvpn_service_config_spec.rb

@ -9,12 +9,12 @@ describe 'Puppet::Type.type(:neutron_bgpvpn_service_config)' do
it 'should autorequire the package that install the file' do
catalog = Puppet::Resource::Catalog.new
package = Puppet::Type.type(:package).new(:name => 'python-networking-bgpvpn')
catalog.add_resource package, @neutron_bgpvpn_service_config
anchor = Puppet::Type.type(:anchor).new(:name => 'neutron::install::end')
catalog.add_resource anchor, @neutron_bgpvpn_service_config
dependency = @neutron_bgpvpn_service_config.autorequire
expect(dependency.size).to eq(1)
expect(dependency[0].target).to eq(@neutron_bgpvpn_service_config)
expect(dependency[0].source).to eq(package)
expect(dependency[0].source).to eq(anchor)
end
end

6
spec/unit/type/neutron_config_spec.rb

@ -54,12 +54,12 @@ describe 'Puppet::Type.type(:neutron_config)' do
it 'should autorequire the package that install the file' do
catalog = Puppet::Resource::Catalog.new
package = Puppet::Type.type(:package).new(:name => 'neutron')
catalog.add_resource package, @neutron_config
anchor = Puppet::Type.type(:anchor).new(:name => 'neutron::install::end')
catalog.add_resource anchor, @neutron_config
dependency = @neutron_config.autorequire
expect(dependency.size).to eq(1)
expect(dependency[0].target).to eq(@neutron_config)
expect(dependency[0].source).to eq(package)
expect(dependency[0].source).to eq(anchor)
end
end

6
spec/unit/type/neutron_dhcp_agent_config_spec.rb

@ -9,12 +9,12 @@ describe 'Puppet::Type.type(:neutron_dhcp_agent_config)' do
it 'should autorequire the package that install the file' do
catalog = Puppet::Resource::Catalog.new
package = Puppet::Type.type(:package).new(:name => 'neutron')
catalog.add_resource package, @neutron_dhcp_agent_config
anchor = Puppet::Type.type(:anchor).new(:name => 'neutron::install::end')
catalog.add_resource anchor, @neutron_dhcp_agent_config
dependency = @neutron_dhcp_agent_config.autorequire
expect(dependency.size).to eq(1)
expect(dependency[0].target).to eq(@neutron_dhcp_agent_config)
expect(dependency[0].source).to eq(package)
expect(dependency[0].source).to eq(anchor)
end
end

6
spec/unit/type/neutron_fwaas_service_config_spec.rb

@ -9,12 +9,12 @@ describe 'Puppet::Type.type(:neutron_fwaas_service_config)' do
it 'should autorequire the package that install the file' do
catalog = Puppet::Resource::Catalog.new
package = Puppet::Type.type(:package).new(:name => 'neutron-fwaas')
catalog.add_resource package, @neutron_fwaas_service_config
anchor = Puppet::Type.type(:anchor).new(:name => 'neutron::install::end')
catalog.add_resource anchor, @neutron_fwaas_service_config
dependency = @neutron_fwaas_service_config.autorequire
expect(dependency.size).to eq(1)
expect(dependency[0].target).to eq(@neutron_fwaas_service_config)
expect(dependency[0].source).to eq(package)
expect(dependency[0].source).to eq(anchor)
end
end

6
spec/unit/type/neutron_l2gw_agent_config_spec.rb

@ -9,12 +9,12 @@ describe 'Puppet::Type.type(:neutron_l2gw_agent_config)' do
it 'should autorequire the package that install the file' do
catalog = Puppet::Resource::Catalog.new
package = Puppet::Type.type(:package).new(:name => 'neutron-l2gw-agent')
catalog.add_resource package, @neutron_l2gw_agent_config
anchor = Puppet::Type.type(:anchor).new(:name => 'neutron::install::end')
catalog.add_resource anchor, @neutron_l2gw_agent_config
dependency = @neutron_l2gw_agent_config.autorequire
expect(dependency.size).to eq(1)
expect(dependency[0].target).to eq(@neutron_l2gw_agent_config)
expect(dependency[0].source).to eq(package)
expect(dependency[0].source).to eq(anchor)
end
end

6
spec/unit/type/neutron_l2gw_service_config_spec.rb

@ -9,12 +9,12 @@ describe 'Puppet::Type.type(:nova_plugin_l2gw)' do
it 'should autorequire the package that install the file' do
catalog = Puppet::Resource::Catalog.new
package = Puppet::Type.type(:package).new(:name => 'python-networking-l2gw')
catalog.add_resource package, @neutron_l2gw_service_config
anchor = Puppet::Type.type(:anchor).new(:name => 'neutron::install::end')
catalog.add_resource anchor, @neutron_l2gw_service_config
dependency = @neutron_l2gw_service_config.autorequire
expect(dependency.size).to eq(1)
expect(dependency[0].target).to eq(@neutron_l2gw_service_config)
expect(dependency[0].source).to eq(package)
expect(dependency[0].source).to eq(anchor)
end
end

6
spec/unit/type/neutron_l3_agent_config_spec.rb

@ -9,12 +9,12 @@ describe 'Puppet::Type.type(:neutron_l3_agent_config)' do
it 'should autorequire the package that install the file' do
catalog = Puppet::Resource::Catalog.new
package = Puppet::Type.type(:package).new(:name => 'neutron')
catalog.add_resource package, @neutron_fwaas_service_config
anchor = Puppet::Type.type(:anchor).new(:name => 'neutron::install::end')
catalog.add_resource anchor, @neutron_fwaas_service_config
dependency = @neutron_fwaas_service_config.autorequire
expect(dependency.size).to eq(1)
expect(dependency[0].target).to eq(@neutron_fwaas_service_config)
expect(dependency[0].source).to eq(package)
expect(dependency[0].source).to eq(anchor)
end
end

6
spec/unit/type/neutron_metadata_agent_config_spec.rb

@ -9,12 +9,12 @@ describe 'Puppet::Type.type(:neutron_metadata_agent_config)' do
it 'should autorequire the package that install the file' do
catalog = Puppet::Resource::Catalog.new
package = Puppet::Type.type(:package).new(:name => 'neutron')
catalog.add_resource package, @neutron_metadata_agent_config
anchor = Puppet::Type.type(:anchor).new(:name => 'neutron::install::end')
catalog.add_resource anchor, @neutron_metadata_agent_config
dependency = @neutron_metadata_agent_config.autorequire
expect(dependency.size).to eq(1)
expect(dependency[0].target).to eq(@neutron_metadata_agent_config)
expect(dependency[0].source).to eq(package)
expect(dependency[0].source).to eq(anchor)
end
end

11
spec/unit/type/neutron_metering_agent_config_spec.rb

@ -9,15 +9,12 @@ describe 'Puppet::Type.type(:neutron_metering_agent_config)' do
it 'should autorequire the package that install the file' do
catalog = Puppet::Resource::Catalog.new
package1 = Puppet::Type.type(:package).new(:name => 'neutron')
package2 = Puppet::Type.type(:package).new(:name => 'neutron-metering-agent')
catalog.add_resource package1, package2, @neutron_metering_agent_config
anchor = Puppet::Type.type(:anchor).new(:name => 'neutron::install::end')
catalog.add_resource anchor, @neutron_metering_agent_config
dependency = @neutron_metering_agent_config.autorequire
expect(dependency.size).to eq(2)
expect(dependency.size).to eq(1)
expect(dependency[0].target).to eq(@neutron_metering_agent_config)
expect(dependency[0].source).to eq(package1)
expect(dependency[1].target).to eq(@neutron_metering_agent_config)
expect(dependency[1].source).to eq(package2)
expect(dependency[0].source).to eq(anchor)
end
end

6
spec/unit/type/neutron_plugin_cisco_credentials_spec.rb

@ -9,12 +9,12 @@ describe 'Puppet::Type.type(:neutron_plugin_cisco_credentials)' do
it 'should autorequire the package that install the file' do
catalog = Puppet::Resource::Catalog.new
package = Puppet::Type.type(:package).new(:name => 'neutron-plugin-cisco')
catalog.add_resource package, @neutron_plugin_cisco_credentials
anchor = Puppet::Type.type(:anchor).new(:name => 'neutron::install::end')
catalog.add_resource anchor, @neutron_plugin_cisco_credentials
dependency = @neutron_plugin_cisco_credentials.autorequire
expect(dependency.size).to eq(1)
expect(dependency[0].target).to eq(@neutron_plugin_cisco_credentials)
expect(dependency[0].source).to eq(package)
expect(dependency[0].source).to eq(anchor)
end
end

6
spec/unit/type/neutron_plugin_cisco_db_conn_spec.rb

@ -9,12 +9,12 @@ describe 'Puppet::Type.type(:neutron_plugin_cisco_db_conn)' do
it 'should autorequire the package that install the file' do
catalog = Puppet::Resource::Catalog.new
package = Puppet::Type.type(:package).new(:name => 'neutron-plugin-cisco')
catalog.add_resource package, @neutron_plugin_cisco_db_conn
anchor = Puppet::Type.type(:anchor).new(:name => 'neutron::install::end')
catalog.add_resource anchor, @neutron_plugin_cisco_db_conn
dependency = @neutron_plugin_cisco_db_conn.autorequire
expect(dependency.size).to eq(1)
expect(dependency[0].target).to eq(@neutron_plugin_cisco_db_conn)
expect(dependency[0].source).to eq(package)
expect(dependency[0].source).to eq(anchor)
end
end

6
spec/unit/type/neutron_plugin_cisco_l2network_spec.rb

@ -9,12 +9,12 @@ describe 'Puppet::Type.type(:neutron_plugin_cisco_l2network)' do
it 'should autorequire the package that install the file' do
catalog = Puppet::Resource::Catalog.new
package = Puppet::Type.type(:package).new(:name => 'neutron-plugin-cisco')
catalog.add_resource package, @neutron_plugin_cisco_l2network
anchor = Puppet::Type.type(:anchor).new(:name => 'neutron::install::end')
catalog.add_resource anchor, @neutron_plugin_cisco_l2network
dependency = @neutron_plugin_cisco_l2network.autorequire
expect(dependency.size).to eq(1)
expect(dependency[0].target).to eq(@neutron_plugin_cisco_l2network)
expect(dependency[0].source).to eq(package)
expect(dependency[0].source).to eq(anchor)
end
end

6
spec/unit/type/neutron_plugin_cisco_spec.rb

@ -9,12 +9,12 @@ describe 'Puppet::Type.type(:nova_plugin_cisco)' do
it 'should autorequire the package that install the file' do
catalog = Puppet::Resource::Catalog.new
package = Puppet::Type.type(:package).new(:name => 'neutron-plugin-cisco')
catalog.add_resource package, @neutron_plugin_cisco
anchor = Puppet::Type.type(:anchor).new(:name => 'neutron::install::end')
catalog.add_resource anchor, @neutron_plugin_cisco
dependency = @neutron_plugin_cisco.autorequire
expect(dependency.size).to eq(1)
expect(dependency[0].target).to eq(@neutron_plugin_cisco)
expect(dependency[0].source).to eq(package)
expect(dependency[0].source).to eq(anchor)
end
end

6
spec/unit/type/neutron_plugin_midonet_spec.rb

@ -9,12 +9,12 @@ describe 'Puppet::Type.type(:neutron_plugin_midonet)' do
it 'should autorequire the package that install the file' do
catalog = Puppet::Resource::Catalog.new
package = Puppet::Type.type(:package).new(:name => 'python-networking-midonet')
catalog.add_resource package, @neutron_plugin_midonet
anchor = Puppet::Type.type(:anchor).new(:name => 'neutron::install::end')
catalog.add_resource anchor, @neutron_plugin_midonet
dependency = @neutron_plugin_midonet.autorequire
expect(dependency.size).to eq(1)
expect(dependency[0].target).to eq(@neutron_plugin_midonet)
expect(dependency[0].source).to eq(package)
expect(dependency[0].source).to eq(anchor)
end
end

6
spec/unit/type/neutron_plugin_ml2_spec.rb

@ -9,12 +9,12 @@ describe 'Puppet::Type.type(:neutron_plugin_ml2)' do
it 'should autorequire the package that install the file' do
catalog = Puppet::Resource::Catalog.new
package = Puppet::Type.type(:package).new(:name => 'neutron-plugin-ml2')
catalog.add_resource package, @neutron_plugin_ml2
anchor = Puppet::Type.type(:anchor).new(:name => 'neutron::install::end')
catalog.add_resource anchor, @neutron_plugin_ml2
dependency = @neutron_plugin_ml2.autorequire
expect(dependency.size).to eq(1)
expect(dependency[0].target).to eq(@neutron_plugin_ml2)
expect(dependency[0].source).to eq(package)
expect(dependency[0].source).to eq(anchor)
end
end

6
spec/unit/type/neutron_plugin_nsx_spec.rb

@ -9,12 +9,12 @@ describe 'Puppet::Type.type(:neutron_plugin_nsx)' do
it 'should autorequire the package that install the file' do
catalog = Puppet::Resource::Catalog.new
package = Puppet::Type.type(:package).new(:name => 'vmware-nsx')
catalog.add_resource package, @neutron_plugin_nsx
anchor = Puppet::Type.type(:anchor).new(:name => 'neutron::install::end')
catalog.add_resource anchor, @neutron_plugin_nsx
dependency = @neutron_plugin_nsx.autorequire
expect(dependency.size).to eq(1)
expect(dependency[0].target).to eq(@neutron_plugin_nsx)
expect(dependency[0].source).to eq(package)
expect(dependency[0].source).to eq(anchor)
end
end

6
spec/unit/type/neutron_plugin_nvp_spec.rb

@ -9,12 +9,12 @@ describe 'Puppet::Type.type(:neutron_plugin_nvp)' do
it 'should autorequire the package that install the file' do
catalog = Puppet::Resource::Catalog.new
package = Puppet::Type.type(:package).new(:name => 'neutron-plugin-nvp')
catalog.add_resource package, @neutron_plugin_nvp
anchor = Puppet::Type.type(:anchor).new(:name => 'neutron::install::end')
catalog.add_resource anchor, @neutron_plugin_nvp
dependency = @neutron_plugin_nvp.autorequire
expect(dependency.size).to eq(1)
expect(dependency[0].target).to eq(@neutron_plugin_nvp)
expect(dependency[0].source).to eq(package)
expect(dependency[0].source).to eq(anchor)
end
end

6
spec/unit/type/neutron_plugin_opencontrail_spec.rb

@ -9,12 +9,12 @@ describe 'Puppet::Type.type(:neutron_plugin_opencontrail)' do
it 'should autorequire the package that install the file' do
catalog = Puppet::Resource::Catalog.new
package = Puppet::Type.type(:package).new(:name => 'neutron-plugin-opencontrail')
catalog.add_resource package, @neutron_plugin_opencontrail
anchor = Puppet::Type.type(:anchor).new(:name => 'neutron::install::end')
catalog.add_resource anchor, @neutron_plugin_opencontrail
dependency = @neutron_plugin_opencontrail.autorequire
expect(dependency.size).to eq(1)
expect(dependency[0].target).to eq(@neutron_plugin_opencontrail)
expect(dependency[0].source).to eq(package)
expect(dependency[0].source).to eq(anchor)
end
end

6
spec/unit/type/neutron_plugin_plumgrid_spec.rb

@ -9,12 +9,12 @@ describe 'Puppet::Type.type(:neutron_plugin_plumgrid)' do
it 'should autorequire the package that install the file' do
catalog = Puppet::Resource::Catalog.new
package = Puppet::Type.type(:package).new(:name => 'neutron-plugin-plumgrid')
catalog.add_resource package, @neutron_plugin_plumgrid
anchor = Puppet::Type.type(:anchor).new(:name => 'neutron::install::end')
catalog.add_resource anchor, @neutron_plugin_plumgrid
dependency = @neutron_plugin_plumgrid.autorequire
expect(dependency.size).to eq(1)
expect(dependency[0].target).to eq(@neutron_plugin_plumgrid)
expect(dependency[0].source).to eq(package)
expect(dependency[0].source).to eq(anchor)
end
end

6
spec/unit/type/neutron_plumlib_plumgrid_spec.rb

@ -9,12 +9,12 @@ describe 'Puppet::Type.type(:neutron_plumlib_plumgrid)' do
it 'should autorequire the package that install the file' do
catalog = Puppet::Resource::Catalog.new
package = Puppet::Type.type(:package).new(:name => 'neutron-plumlib-plumgrid')
catalog.add_resource package, @neutron_plumlib_plumgrid
anchor = Puppet::Type.type(:anchor).new(:name => 'neutron::install::end')
catalog.add_resource anchor, @neutron_plumlib_plumgrid
dependency = @neutron_plumlib_plumgrid.autorequire
expect(dependency.size).to eq(1)
expect(dependency[0].target).to eq(@neutron_plumlib_plumgrid)
expect(dependency[0].source).to eq(package)
expect(dependency[0].source).to eq(anchor)
end
end

6
spec/unit/type/neutron_rootwrap_config_spec.rb

@ -9,12 +9,12 @@ describe 'Puppet::Type.type(:neutron_rootwrap_config)' do
it 'should autorequire the package that install the file' do
catalog = Puppet::Resource::Catalog.new
package = Puppet::Type.type(:package).new(:name => 'neutron-common')
catalog.add_resource package, @neutron_rootwrap_config
anchor = Puppet::Type.type(:anchor).new(:name => 'neutron::install::end')
catalog.add_resource anchor, @neutron_rootwrap_config
dependency = @neutron_rootwrap_config.autorequire
expect(dependency.size).to eq(1)
expect(dependency[0].target).to eq(@neutron_rootwrap_config)
expect(dependency[0].source).to eq(package)
expect(dependency[0].source).to eq(anchor)
end
end