From 623d5b914f183c44a6b7011f2b79b0f0318b5988 Mon Sep 17 00:00:00 2001 From: vic Date: Fri, 22 Mar 2013 12:47:12 +0400 Subject: [PATCH] Test standalone quantum node --- fuel_test/cobbler/test_compact.py | 21 ++++++++++++++++----- fuel_test/manifest.py | 7 ++++--- 2 files changed, 20 insertions(+), 8 deletions(-) diff --git a/fuel_test/cobbler/test_compact.py b/fuel_test/cobbler/test_compact.py index 78a142b4de..1263f7aff7 100644 --- a/fuel_test/cobbler/test_compact.py +++ b/fuel_test/cobbler/test_compact.py @@ -6,7 +6,7 @@ from fuel_test.settings import CREATE_SNAPSHOTS class CompactTestCase(CobblerTestCase): - def deploy_compact(self, quantum=True, loopback=True): + def deploy_compact(self, quantum_node=True, loopback=True): self.do(self.nodes().controllers[:1], 'puppet agent --test 2>&1') self.do(self.nodes().controllers[1:], 'puppet agent --test 2>&1') if loopback: @@ -14,7 +14,7 @@ class CompactTestCase(CobblerTestCase): self.do(self.nodes().controllers[:1], 'puppet agent --test 2>&1') self.do(self.nodes().controllers[1:], 'puppet agent --test 2>&1') self.validate(self.nodes().controllers, 'puppet agent --test 2>&1') - if quantum: + if quantum_node: self.validate(self.nodes().quantums, 'puppet agent --test 2>&1') self.validate(self.nodes().computes, 'puppet agent --test 2>&1') @@ -26,7 +26,18 @@ class CompactTestCase(CobblerTestCase): controllers=self.nodes().controllers, quantums=self.nodes().quantums, quantum=True) - self.deploy_compact() + self.deploy_compact(quantum_node=False) + if CREATE_SNAPSHOTS: + self.environment().snapshot('compact', force=True) + + def test_deploy_compact_quantum_standalone(self): + Manifest().write_openstack_manifest( + remote=self.remote(), + template=Template.compact(), ci=self.ci(), + controllers=self.nodes().controllers, + quantums=self.nodes().quantums, + quantum=True, quantum_netnode_on_cnt=False) + self.deploy_compact(quantum_node=True) if CREATE_SNAPSHOTS: self.environment().snapshot('compact', force=True) @@ -37,7 +48,7 @@ class CompactTestCase(CobblerTestCase): controllers=self.nodes().controllers, quantums=self.nodes().quantums, quantum=False) - self.deploy_compact(quantum=False) + self.deploy_compact(quantum_node=False) if CREATE_SNAPSHOTS: self.environment().snapshot('compact_wo_quantum', force=True) @@ -48,7 +59,7 @@ class CompactTestCase(CobblerTestCase): controllers=self.nodes().controllers, quantums=self.nodes().quantums, quantum=False, loopback=False, use_syslog=False) - self.deploy_compact(quantum=False, loopback=False) + self.deploy_compact(quantum_node=False, loopback=False) if CREATE_SNAPSHOTS: self.environment().snapshot('compact_woloopback', force=True) diff --git a/fuel_test/manifest.py b/fuel_test/manifest.py index 19c6605509..31c8720347 100644 --- a/fuel_test/manifest.py +++ b/fuel_test/manifest.py @@ -254,7 +254,7 @@ class Manifest(object): def write_openstack_ha_minimal_manifest(self, remote, template, ci, controllers, quantums, proxies=None, use_syslog=True, quantum=True, loopback=True, - cinder=True, cinder_on_computes=False): + cinder=True, cinder_on_computes=False, quantum_netnode_on_cnt=True): template.replace( internal_virtual_ip=ci.internal_virtual_ip(), public_virtual_ip=ci.public_virtual_ip(), @@ -282,7 +282,7 @@ class Manifest(object): if is_not_essex(): template.replace( quantum=quantum, - quantum_netnode_on_cnt=quantum, + quantum_netnode_on_cnt=quantum_netnode_on_cnt, ) self.write_manifest(remote, template) @@ -291,7 +291,7 @@ class Manifest(object): def write_openstack_manifest(self, remote, template, ci, controllers, quantums, proxies=None, use_syslog=True, quantum=True, loopback=True, - cinder=True, swift=True): + cinder=True, swift=True, quantum_netnode_on_cnt=True): template.replace( internal_virtual_ip=ci.internal_virtual_ip(), public_virtual_ip=ci.public_virtual_ip(), @@ -321,6 +321,7 @@ class Manifest(object): if is_not_essex(): template.replace( quantum=quantum, + quantum_netnode_on_cnt=quantum_netnode_on_cnt, ) self.write_manifest(remote, template)