Amulet test fixes:

* Makefile: Only run precise-icehouse and trusty-icehouse tests by default
    and increase test timeout
  * t/00-setup: Add more required dependencies
  * t/README: Mention charm-tools dependency
  * t/basic_deployment.py:
    - Specify unstable charm deployment
    - Use dicts in add_services
This commit is contained in:
Corey Bryant 2014-09-27 18:15:47 +00:00
parent 0e6462f874
commit e4997e2eb8
4 changed files with 22 additions and 12 deletions

View File

@ -10,7 +10,8 @@ test:
# coreycb note: The -v should only be temporary until Amulet sends
# raise_status() messages to stderr:
# https://bugs.launchpad.net/amulet/+bug/1320357
@juju test -v -p AMULET_HTTP_PROXY
@juju test -v -p AMULET_HTTP_PROXY --timeout 900 \
00-setup 14-basic-precise-icehouse 15-basic-trusty-icehouse
bin/charm_helpers_sync.py:
@mkdir -p bin

View File

@ -4,5 +4,7 @@ set -ex
sudo add-apt-repository --yes ppa:juju/stable
sudo apt-get update --yes
sudo apt-get install --yes python-amulet
sudo apt-get install --yes python-keystoneclient
sudo apt-get install --yes python-amulet \
python-keystoneclient \
python-glanceclient \
python-novaclient

View File

@ -1,6 +1,12 @@
This directory provides Amulet tests that focus on verification of ceph
deployments.
In order to run tests, you'll need charm-tools installed (in addition to
juju, of course):
sudo add-apt-repository ppa:juju/stable
sudo apt-get update
sudo apt-get install charm-tools
If you use a web proxy server to access the web, you'll need to set the
AMULET_HTTP_PROXY environment variable to the http URL of the proxy server.

View File

@ -17,9 +17,9 @@ u = OpenStackAmuletUtils(ERROR)
class CephBasicDeployment(OpenStackAmuletDeployment):
"""Amulet tests on a basic ceph deployment."""
def __init__(self, series=None, openstack=None, source=None):
def __init__(self, series=None, openstack=None, source=None, stable=False):
"""Deploy the entire test environment."""
super(CephBasicDeployment, self).__init__(series, openstack, source)
super(CephBasicDeployment, self).__init__(series, openstack, source, stable)
self._add_services()
self._add_relations()
self._configure_services()
@ -29,14 +29,15 @@ class CephBasicDeployment(OpenStackAmuletDeployment):
def _add_services(self):
"""Add services
Add the services that we're testing, including the number of units,
where ceph is local, and mysql and cinder are from the charm
store.
Add the services that we're testing, where ceph is local,
and the rest of the service are from lp branches that are
compatible with the local charm (e.g. stable or next).
"""
this_service = ('ceph', 3)
other_services = [('mysql', 1), ('keystone', 1),
('rabbitmq-server', 1), ('nova-compute', 1),
('glance', 1), ('cinder', 1)]
this_service = {'name': 'ceph', 'units': 3}
other_services = [{'name': 'mysql'}, {'name': 'keystone'},
{'name': 'rabbitmq-server'},
{'name': 'nova-compute'},
{'name': 'glance'}, {'name': 'cinder'}]
super(CephBasicDeployment, self)._add_services(this_service,
other_services)