def test_post_plugin_validation(self): self.assertIsNone(validate_post_plugin_load()) cfg.CONF.set_override('dhcp_agents_per_network', 2) self.assertIsNone(validate_post_plugin_load()) cfg.CONF.set_override('dhcp_agents_per_network', 0) self.assertIsNotNone(validate_post_plugin_load()) cfg.CONF.set_override('dhcp_agents_per_network', -1) self.assertIsNotNone(validate_post_plugin_load())
def test_post_plugin_validation(self): cfg.CONF.import_opt("dhcp_agents_per_network", "neutron.db.agentschedulers_db") self.assertIsNone(manager.validate_post_plugin_load()) cfg.CONF.set_override("dhcp_agents_per_network", 2) self.assertIsNone(manager.validate_post_plugin_load()) cfg.CONF.set_override("dhcp_agents_per_network", 0) self.assertIsNotNone(manager.validate_post_plugin_load()) cfg.CONF.set_override("dhcp_agents_per_network", -1) self.assertIsNotNone(manager.validate_post_plugin_load())
def test_post_plugin_validation(self): cfg.CONF.import_opt('dhcp_agents_per_network', 'neutron.db.agentschedulers_db') self.assertIsNone(validate_post_plugin_load()) cfg.CONF.set_override('dhcp_agents_per_network', 2) self.assertIsNone(validate_post_plugin_load()) cfg.CONF.set_override('dhcp_agents_per_network', 0) self.assertIsNotNone(validate_post_plugin_load()) cfg.CONF.set_override('dhcp_agents_per_network', -1) self.assertIsNotNone(validate_post_plugin_load())