From 5e72ecd5adf70b52f70e64fe7663b132739d4c5e Mon Sep 17 00:00:00 2001 From: "Sean M. Collins" Date: Wed, 24 Feb 2016 14:03:21 -0500 Subject: [PATCH] Fix calls to create_ovs_vif_port create_ovs_vif_port has six required arguments: * bridge * dev * iface_id * mac * instance_id * mtu And an optional argument - timeout. However calls to create_ovs_vif_port only supplied five of six required arguments and the optional argument, and mocks to the call also had the incorrect number of arguments. Therefore the unit tests passed but any code that actually called create_ovs_vif_port would have thrown an error. Change-Id: Ic165557da57cf6df1fd39309b16e0a89a02df16d --- vif_plug_ovs/ovs_hybrid.py | 1 + vif_plug_ovs/tests/test_plugin.py | 1 + 2 files changed, 2 insertions(+) diff --git a/vif_plug_ovs/ovs_hybrid.py b/vif_plug_ovs/ovs_hybrid.py index a8237f6..5d20262 100644 --- a/vif_plug_ovs/ovs_hybrid.py +++ b/vif_plug_ovs/ovs_hybrid.py @@ -115,6 +115,7 @@ class OvsHybridPlugin(plugin.PluginBase): v2_name, vif.port_profile.interface_id, vif.address, instance_info.uuid, + self.config.network_device_mtu, timeout=self.config.ovs_vsctl_timeout) def unplug(self, vif, instance_info): diff --git a/vif_plug_ovs/tests/test_plugin.py b/vif_plug_ovs/tests/test_plugin.py index efd597d..584f4be 100644 --- a/vif_plug_ovs/tests/test_plugin.py +++ b/vif_plug_ovs/tests/test_plugin.py @@ -95,6 +95,7 @@ class PluginTest(testtools.TestCase): 'br0', 'qvovif-xxx-yyy', 'aaa-bbb-ccc', 'ca:fe:de:ad:be:ef', 'f0000000-0000-0000-0000-000000000001', + 1500, timeout=120)] } # The disable_ipv6 call needs to be added in the middle, if required