예제 #1
0
 def test_allocates_vip(self):
     self.addCleanup(cfg.CONF.clear_override,
                     'allocates_vip',
                     group='octavia')
     cfg.CONF.set_override('allocates_vip', True, group='octavia')
     test_driver = driver.OctaviaDriver(self.plugin)
     self.assertEqual(True, test_driver.load_balancer.allocates_vip)
예제 #2
0
 def setUp(self):
     super(BaseOctaviaDriverTest, self).setUp()
     self.context = context.get_admin_context()
     self.plugin = mock.Mock()
     self.driver = driver.OctaviaDriver(self.plugin)
     # mock of rest call.
     self.driver.req = mock.Mock()
     self.lb = self._create_fake_models()
예제 #3
0
 def setUp(self):
     super(test_octavia_driver.BaseOctaviaDriverTest, self).setUp()
     self.plugin = mock.Mock()
     self.driver = odriver.OctaviaDriver(self.plugin)