diff options
| author | Josh Kearney <josh.kearney@rackspace.com> | 2011-03-14 16:21:33 -0500 |
|---|---|---|
| committer | Josh Kearney <josh.kearney@rackspace.com> | 2011-03-14 16:21:33 -0500 |
| commit | 408a2591d60f5d238e60e4be9197ccc7262f2406 (patch) | |
| tree | e997aeb294521fc89d6b846a9d3c29d112549ff5 /nova | |
| parent | 119bbe04f3c1de06a8c40502c314f13c89561564 (diff) | |
| download | nova-408a2591d60f5d238e60e4be9197ccc7262f2406.tar.gz nova-408a2591d60f5d238e60e4be9197ccc7262f2406.tar.xz nova-408a2591d60f5d238e60e4be9197ccc7262f2406.zip | |
PEP8 cleanup
Diffstat (limited to 'nova')
| -rw-r--r-- | nova/tests/db/fakes.py | 4 | ||||
| -rw-r--r-- | nova/tests/test_xenapi.py | 11 | ||||
| -rw-r--r-- | nova/virt/xenapi/vm_utils.py | 3 |
3 files changed, 8 insertions, 10 deletions
diff --git a/nova/tests/db/fakes.py b/nova/tests/db/fakes.py index 142f6b1c6..5e9a3aa3b 100644 --- a/nova/tests/db/fakes.py +++ b/nova/tests/db/fakes.py @@ -77,8 +77,8 @@ def stub_out_db_instance_api(stubs): 'mac_address': values['mac_address'], 'vcpus': type_data['vcpus'], 'local_gb': type_data['local_gb'], - 'os_type': values['os_type'] - } + 'os_type': values['os_type']} + return FakeModel(base_options) def fake_network_get_by_instance(context, instance_id): diff --git a/nova/tests/test_xenapi.py b/nova/tests/test_xenapi.py index cd125a301..8b0affd5c 100644 --- a/nova/tests/test_xenapi.py +++ b/nova/tests/test_xenapi.py @@ -78,8 +78,7 @@ class XenAPIVolumeTestCase(test.TestCase): 'ramdisk_id': 3, 'instance_type': 'm1.large', 'mac_address': 'aa:bb:cc:dd:ee:ff', - 'os_type': 'linux' - } + 'os_type': 'linux'} def _create_volume(self, size='0'): """Create a volume object.""" @@ -315,8 +314,8 @@ class XenAPIVMTestCase(test.TestCase): 'ramdisk_id': ramdisk_id, 'instance_type': instance_type, 'mac_address': 'aa:bb:cc:dd:ee:ff', - 'os_type': os_type - } + 'os_type': os_type} + conn = xenapi_conn.get_connection(False) instance = db.instance_create(values) conn.spawn(instance) @@ -440,8 +439,8 @@ class XenAPIMigrateInstance(test.TestCase): 'ramdisk_id': None, 'instance_type': 'm1.large', 'mac_address': 'aa:bb:cc:dd:ee:ff', - 'os_type': 'linux' - } + 'os_type': 'linux'} + stubs.stub_out_migration_methods(self.stubs) glance_stubs.stubout_glance_client(self.stubs, glance_stubs.FakeGlance) diff --git a/nova/virt/xenapi/vm_utils.py b/nova/virt/xenapi/vm_utils.py index f07b57796..763c5fe40 100644 --- a/nova/virt/xenapi/vm_utils.py +++ b/nova/virt/xenapi/vm_utils.py @@ -136,8 +136,7 @@ class VMHelper(HelperBase): 'VCPUs_at_startup': vcpus, 'VCPUs_max': vcpus, 'VCPUs_params': {}, - 'xenstore_data': {} - } + 'xenstore_data': {}} # Complete VM configuration record according to the image type # non-raw/raw with PV kernel/raw in HVM mode |
