Fix backend_name and section name mismatch
Change-Id: I16a56250dfea62630bcc096fcda194b81316da48
This commit is contained in:
parent
ad443c2d8e
commit
c6b3544ae3
@ -77,7 +77,7 @@ class CinderStoragePluginCharm(ops_openstack.core.OSBaseCharm):
|
||||
|
||||
def set_data(self, data, config, app_name):
|
||||
"""Inform another charm of the backend name and configuration."""
|
||||
data['backend_name'] = config['volume-backend-name'] or app_name
|
||||
data['backend_name'] = app_name
|
||||
data['stateless'] = str(self.stateless)
|
||||
data['active_active'] = str(self.active_active)
|
||||
data['subordinate_configuration'] = self.render_config(
|
||||
|
@ -127,19 +127,12 @@ class TestBaseCinderCharm(unittest.TestCase):
|
||||
juju-info:
|
||||
interface: juju-info
|
||||
scope: container
|
||||
''',
|
||||
config='''
|
||||
options:
|
||||
volume-backend-name:
|
||||
default: ""
|
||||
type: string
|
||||
'''
|
||||
)
|
||||
self.addCleanup(self.harness.cleanup)
|
||||
self.harness.begin()
|
||||
self.harness.set_leader(True)
|
||||
backend = self.harness.add_relation('storage-backend', 'cinder')
|
||||
self.harness.update_config({'volume-backend-name': 'test'})
|
||||
self.harness.add_relation_unit(backend, 'cinder/0')
|
||||
|
||||
def test_cinder_base(self):
|
||||
|
Loading…
Reference in New Issue
Block a user