7
class TestDeployment(unittest.TestCase):
10
cls.deployment = amulet.Deployment(series='trusty')
11
cls.deployment.load_bundle_file(
12
bundle_file='tests/files/neutron-api-plumgrid.yaml',
13
deployment_name='test')
15
cls.deployment.setup(timeout=2000)
16
cls.deployment.sentry.wait()
17
except amulet.helpers.TimeoutError:
19
amulet.SKIP, msg="Environment wasn't stood up in time")
23
def test_packages_installed(self):
24
pg_sentry = self.deployment.sentry['neutron-api/0']
25
for package in {'plumgrid-pythonlib'}:
26
output, code = pg_sentry.run("dpkg -l {}".format(package))
28
message = "{} package not found.".format(package)
29
amulet.raise_status(amulet.FAIL, msg=message)
31
def test_config_file_present(self):
33
config_file = self.deployment.sentry['neutron-api/0'].file(
34
'/etc/neutron/plugins/plumgrid/plumlib.ini')
37
amulet.FAIL, msg='plumlib.ini not found.')
40
amulet.FAIL, msg='plumlib.ini inaccessible.')
42
if __name__ == '__main__':