diff --git a/quantum/extensions/l3.py b/quantum/extensions/l3.py index 5071333471..15542d31ae 100644 --- a/quantum/extensions/l3.py +++ b/quantum/extensions/l3.py @@ -249,3 +249,9 @@ class RouterPluginBase(object): @abstractmethod def get_floatingips(self, context, filters=None, fields=None): pass + + def get_routers_count(self, context, filters=None): + raise qexception.NotImplementedError() + + def get_floatingips_count(self, context, filters=None): + raise qexception.NotImplementedError() diff --git a/quantum/plugins/cisco/models/virt_phy_sw_v2.py b/quantum/plugins/cisco/models/virt_phy_sw_v2.py index 1586c0016f..1d6622e5e0 100644 --- a/quantum/plugins/cisco/models/virt_phy_sw_v2.py +++ b/quantum/plugins/cisco/models/virt_phy_sw_v2.py @@ -289,10 +289,6 @@ class VirtualPhysicalSwitchModelV2(quantum_plugin_base_v2.QuantumPluginBaseV2): """For this model this method will be delegated to vswitch plugin""" pass - def get_networks_count(self, context, filters=None): - """For this model this method will be delegated to vswitch plugin""" - pass - def create_port(self, context, port): """For this model this method will be delegated to vswitch plugin""" pass @@ -305,10 +301,6 @@ class VirtualPhysicalSwitchModelV2(quantum_plugin_base_v2.QuantumPluginBaseV2): """For this model this method will be delegated to vswitch plugin""" pass - def get_ports_count(self, context, filters=None): - """For this model this method will be delegated to vswitch plugin""" - pass - def update_port(self, context, id, port): """For this model this method will be delegated to vswitch plugin""" pass @@ -336,7 +328,3 @@ class VirtualPhysicalSwitchModelV2(quantum_plugin_base_v2.QuantumPluginBaseV2): def get_subnets(self, context, filters=None, fields=None): """For this model this method will be delegated to vswitch plugin""" pass - - def get_subnets_count(self, context, filters=None): - """For this model this method will be delegated to vswitch plugin""" - pass diff --git a/quantum/tests/unit/test_l3_plugin.py b/quantum/tests/unit/test_l3_plugin.py index f171878854..fe0a0b6001 100644 --- a/quantum/tests/unit/test_l3_plugin.py +++ b/quantum/tests/unit/test_l3_plugin.py @@ -117,6 +117,7 @@ class L3NatExtensionTestCase(unittest.TestCase): instance = self.plugin.return_value instance.create_router.return_value = return_value + instance.get_routers_count.return_value = 0 res = self.api.post_json(_get_path('routers'), data)