Fix test_amqp_changed_with_data_and_quantum to take into account the neutron-api relation check and add additional test to check neutron conf isn't written when relation is present
This commit is contained in:
parent
0f59e514bc
commit
c38fd8ec3d
@ -170,11 +170,19 @@ class NovaComputeRelationsTests(CharmTestCase):
|
||||
|
||||
@patch.object(hooks, 'CONFIGS')
|
||||
def test_amqp_changed_with_data_and_quantum(self, configs):
|
||||
self.relation_ids.return_value = []
|
||||
self._amqp_test(configs, quantum=True)
|
||||
self.assertEquals([call('/etc/nova/nova.conf'),
|
||||
call('/etc/quantum/quantum.conf')],
|
||||
configs.write.call_args_list)
|
||||
|
||||
@patch.object(hooks, 'CONFIGS')
|
||||
def test_amqp_changed_with_data_and_quantum_api(self, configs):
|
||||
self.relation_ids.return_value = ['neutron-plugin:0']
|
||||
self._amqp_test(configs, quantum=True)
|
||||
self.assertEquals([call('/etc/nova/nova.conf')],
|
||||
configs.write.call_args_list)
|
||||
|
||||
def test_db_joined(self):
|
||||
self.unit_get.return_value = 'nova.foohost.com'
|
||||
self.is_relation_made.return_value = False
|
||||
|
Loading…
Reference in New Issue
Block a user