Enable Zesty-Ocata Amulet Tests

- Turn on Zesty-Ocata Amulet test definitions.
- Standardize test-requirements.txt
- Sync charm helpers for various fixes

Change-Id: I18aad5b3becc622643f9dee155ecd197b4e680f6
This commit is contained in:
David Ames 2017-04-27 11:21:57 -07:00
parent 94aea2925f
commit f694607b9e
8 changed files with 46 additions and 24 deletions

View File

@ -1,3 +1,2 @@
#charm-tools
git+https://github.com/juju/charm-tools#egg=charm-tools
charm-tools
simplejson

View File

@ -16,6 +16,7 @@ tags:
- openstack
series:
- xenial
- yakkety
- zesty
subordinate: true
provides:

View File

@ -1,22 +1,33 @@
# charm-proof
# The order of packages is significant, because pip processes them in the order
# of appearance. Changing the order has an impact on the overall integration
# process, which may cause wedges in the gate later.
coverage>=3.6
mock>=1.2
flake8>=2.2.4,<=2.4.1
os-testr>=0.4.1
charm-tools>=2.0.0
requests==2.6.0
# amulet deployment helpers
bzr+lp:charm-helpers#egg=charmhelpers
# BEGIN: Amulet OpenStack Charm Helper Requirements
# Liberty client lower constraints
amulet>=1.14.3,<2.0
bundletester>=0.6.1,<1.0
python-keystoneclient>=1.7.1,<2.0
python-barbicanclient>=4.0.1,<5.0
python-designateclient>=1.5,<2.0
python-cinderclient>=1.4.0,<2.0
python-glanceclient>=1.1.0,<2.0
python-heatclient>=0.8.0,<1.0
python-neutronclient>=3.1.0,<4.0
python-novaclient>=2.30.1,<3.0
python-openstackclient>=1.7.0,<2.0
python-swiftclient>=2.6.0,<3.0
python-manilaclient>=1.8.1,<2.0
aodhclient>=0.1.0
python-barbicanclient>=4.0.1
python-ceilometerclient>=1.5.0
python-cinderclient>=1.4.0
python-designateclient>=1.5
python-glanceclient>=1.1.0
python-heatclient>=0.8.0
python-keystoneclient>=1.7.1
python-manilaclient>=1.8.1
python-neutronclient>=3.1.0
python-novaclient>=2.30.1
python-openstackclient>=1.7.0
python-swiftclient>=2.6.0
pika>=0.10.0,<1.0
distro-info
# END: Amulet OpenStack Charm Helper Requirements
# NOTE: workaround for 14.04 pip/tox
pytz

View File

@ -44,7 +44,7 @@ class ManilaGenericBasicDeployment(OpenStackAmuletDeployment):
self._deploy()
u.log.info('Waiting on extended status checks...')
exclude_services = ['mysql', ]
exclude_services = []
self._auto_wait_for_status(exclude_services=exclude_services)
self._initialize_tests()
@ -58,8 +58,7 @@ class ManilaGenericBasicDeployment(OpenStackAmuletDeployment):
"""
this_service = {'name': 'manila-generic'}
other_services = [
{'name': 'mysql',
'location': 'cs:percona-cluster',
{'name': 'percona-cluster',
'constraints': {'mem': '3072M'}},
{'name': 'rabbitmq-server'},
{'name': 'keystone'},
@ -71,11 +70,11 @@ class ManilaGenericBasicDeployment(OpenStackAmuletDeployment):
def _add_relations(self):
"""Add all of the relations for the services."""
relations = {
'manila:shared-db': 'mysql:shared-db',
'manila:shared-db': 'percona-cluster:shared-db',
'manila:amqp': 'rabbitmq-server:amqp',
'manila:identity-service': 'keystone:identity-service',
'manila:manila-plugin': 'manila-generic:manila-plugin',
'keystone:shared-db': 'mysql:shared-db',
'keystone:shared-db': 'percona-cluster:shared-db',
}
super(ManilaGenericBasicDeployment, self)._add_relations(relations)
@ -103,7 +102,7 @@ class ManilaGenericBasicDeployment(OpenStackAmuletDeployment):
# Access the sentries for inspecting service units
self.manila_sentry = self.d.sentry['manila'][0]
self.manila_generic_sentry = self.d.sentry['manila-generic'][0]
self.mysql_sentry = self.d.sentry['mysql'][0]
self.percona_cluster_sentry = self.d.sentry['percona-cluster'][0]
self.keystone_sentry = self.d.sentry['keystone'][0]
self.rabbitmq_sentry = self.d.sentry['rabbitmq-server'][0]
u.log.debug('openstack release val: {}'.format(
@ -112,7 +111,7 @@ class ManilaGenericBasicDeployment(OpenStackAmuletDeployment):
self._get_openstack_release_string()))
keystone_ip = self.keystone_sentry.relation(
'shared-db', 'mysql:shared-db')['private-address']
'shared-db', 'percona-cluster:shared-db')['private-address']
# We need to auth either to v2.0 or v3 keystone
if self._keystone_version == '2':

View File

@ -0,0 +1,10 @@
#!/usr/bin/env python
"""Amulet tests on a basic barbican deployment on yakkety-newton for keystone v2.
"""
from basic_deployment import ManilaGenericBasicDeployment
if __name__ == '__main__':
deployment = ManilaGenericBasicDeployment(series='yakkety', keystone_version='2')
deployment.run_tests()

0
src/tests/gate-basic-zesty-ocata Normal file → Executable file
View File

View File

@ -10,7 +10,7 @@ setenv = VIRTUAL_ENV={envdir}
PYTHONHASHSEED=0
AMULET_SETUP_TIMEOUT=2700
whitelist_externals = juju
passenv = HOME TERM AMULET_*
passenv = HOME TERM AMULET_* CS_API_*
deps = -r{toxinidir}/test-requirements.txt
install_command =
pip install --allow-unverified python-apt {opts} {packages}

View File

@ -1,3 +1,6 @@
# Source charm: ./tox.ini
# This file is managed centrally by release-tools and should not be modified
# within individual charm repos.
[tox]
skipsdist = True
envlist = pep8,py34,py35
@ -7,7 +10,6 @@ skip_missing_interpreters = True
setenv = VIRTUAL_ENV={envdir}
PYTHONHASHSEED=0
TERM=linux
INTERFACE_PATH={toxinidir}/interfaces
LAYER_PATH={toxinidir}/layers
INTERFACE_PATH={toxinidir}/interfaces
JUJU_REPOSITORY={toxinidir}/build
@ -41,7 +43,7 @@ deps = -r{toxinidir}/test-requirements.txt
commands = ostestr {posargs}
[testenv:pep8]
basepython = python2.7
basepython = python3.5
deps = -r{toxinidir}/test-requirements.txt
commands = flake8 {posargs} src unit_tests