Test that names are created correctly

This commit is contained in:
Ben Firshman 2013-12-09 18:42:33 +00:00
parent 39497f6ee7
commit 2199b62783
1 changed files with 5 additions and 0 deletions

View File

@ -27,6 +27,7 @@ class ContainersTestCase(ServiceTestCase):
foo.start()
self.assertEqual(len(foo.containers), 1)
self.assertEqual(foo.containers[0]['Names'], ['/foo_1'])
self.assertEqual(len(bar.containers), 0)
bar.scale(2)
@ -34,6 +35,10 @@ class ContainersTestCase(ServiceTestCase):
self.assertEqual(len(foo.containers), 1)
self.assertEqual(len(bar.containers), 2)
names = [c['Names'] for c in bar.containers]
self.assertIn(['/bar_1'], names)
self.assertIn(['/bar_2'], names)
class ScalingTestCase(ServiceTestCase):
def setUp(self):