Merge pull request #2649 from dnephin/make_volumes_from_more_explicit
Make volumes from more explicit in V2 config format
This commit is contained in:
commit
8fca4f1628
13 changed files with 237 additions and 129 deletions
|
|
@ -81,7 +81,7 @@ class ProjectTest(DockerClientTestCase):
|
|||
)
|
||||
db = project.get_service('db')
|
||||
data = project.get_service('data')
|
||||
self.assertEqual(db.volumes_from, [VolumeFromSpec(data, 'rw')])
|
||||
self.assertEqual(db.volumes_from, [VolumeFromSpec(data, 'rw', 'service')])
|
||||
|
||||
def test_volumes_from_container(self):
|
||||
data_container = Container.create(
|
||||
|
|
|
|||
|
|
@ -224,8 +224,8 @@ class ServiceTest(DockerClientTestCase):
|
|||
host_service = self.create_service(
|
||||
'host',
|
||||
volumes_from=[
|
||||
VolumeFromSpec(volume_service, 'rw'),
|
||||
VolumeFromSpec(volume_container_2, 'rw')
|
||||
VolumeFromSpec(volume_service, 'rw', 'service'),
|
||||
VolumeFromSpec(volume_container_2, 'rw', 'container')
|
||||
]
|
||||
)
|
||||
host_container = host_service.create_container()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue