Enable functional tests for train
This patch also updates the smoke test to run train. Change-Id: I8f3a4b38571ab560564d135f69664c294820158e Signed-off-by: Sahid Orentino Ferdjaoui <sahid.ferdjaoui@canonical.com>
This commit is contained in:
parent
bb0c9725a7
commit
b8201a09ee
|
@ -113,8 +113,10 @@ class CinderCephBasicDeployment(OpenStackAmuletDeployment):
|
|||
|
||||
ceph_config = {
|
||||
'monitor-count': '3',
|
||||
'auth-supported': 'none',
|
||||
}
|
||||
if self._get_openstack_release() < self.bionic_train:
|
||||
ceph_config['auth-supported'] = 'none'
|
||||
|
||||
cinder_ceph_config = {
|
||||
'ceph-osd-replication-count': '3',
|
||||
}
|
||||
|
@ -327,6 +329,9 @@ class CinderCephBasicDeployment(OpenStackAmuletDeployment):
|
|||
'ceph-public-address': u.valid_ip,
|
||||
'auth': 'none',
|
||||
}
|
||||
if self._get_openstack_release() >= self.bionic_train:
|
||||
expected['auth'] = 'cephx'
|
||||
|
||||
ret = u.validate_relation_data(ceph_unit, relation, expected)
|
||||
if ret:
|
||||
msg = u.relation_error('cinder cinder-ceph storage-backend', ret)
|
||||
|
@ -563,6 +568,9 @@ class CinderCephBasicDeployment(OpenStackAmuletDeployment):
|
|||
# 'log to syslog': 'false'
|
||||
}
|
||||
}
|
||||
if self._get_openstack_release() >= self.bionic_train:
|
||||
expected['global']['auth_supported'] = 'cephx'
|
||||
|
||||
for section, pairs in expected.iteritems():
|
||||
ret = u.validate_config_data(unit, conf, section, pairs)
|
||||
if ret:
|
||||
|
@ -714,11 +722,12 @@ class CinderCephBasicDeployment(OpenStackAmuletDeployment):
|
|||
all ceph units, and the cinder-ceph unit."""
|
||||
u.log.debug('Checking exit values are 0 on ceph commands')
|
||||
sentry_units = [
|
||||
self.cinder_ceph_sentry,
|
||||
self.ceph0_sentry,
|
||||
self.ceph1_sentry,
|
||||
self.ceph2_sentry
|
||||
]
|
||||
if self._get_openstack_release() < self.bionic_train:
|
||||
sentry_units.append(self.cinder_ceph_sentry)
|
||||
commands = [
|
||||
'sudo ceph health',
|
||||
'sudo ceph mds stat',
|
||||
|
|
|
@ -0,0 +1,25 @@
|
|||
#!/usr/bin/env python
|
||||
#
|
||||
# Copyright 2019 Canonical Ltd
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
"""Amulet tests on a basic cinder-ceph deployment on bionic-train."""
|
||||
|
||||
from basic_deployment import CinderCephBasicDeployment
|
||||
|
||||
if __name__ == '__main__':
|
||||
deployment = CinderCephBasicDeployment(series='bionic',
|
||||
openstack='cloud:bionic-train',
|
||||
source='cloud:bionic-train')
|
||||
deployment.run_tests()
|
2
tox.ini
2
tox.ini
|
@ -105,7 +105,7 @@ basepython = python2.7
|
|||
deps = -r{toxinidir}/requirements.txt
|
||||
-r{toxinidir}/test-requirements.txt
|
||||
commands =
|
||||
bundletester -vl DEBUG -r json -o func-results.json gate-basic-bionic-stein --no-destroy
|
||||
bundletester -vl DEBUG -r json -o func-results.json gate-basic-bionic-train --no-destroy
|
||||
|
||||
[testenv:func-dev]
|
||||
# Charm Functional Test
|
||||
|
|
Loading…
Reference in New Issue