2018-02-12 04:17:53 +00:00
|
|
|
from .manifests import merge_manifest_data
|
|
|
|
from .tools import boot_manifest
|
2015-12-13 19:26:11 +01:00
|
|
|
|
|
|
|
partials = {'docker': '''
|
|
|
|
provider:
|
|
|
|
name: docker
|
|
|
|
virtualization: hvm
|
|
|
|
dockerfile: CMD /bin/bash
|
|
|
|
bootstrapper:
|
|
|
|
variant: minbase
|
|
|
|
system:
|
|
|
|
bootloader: none
|
|
|
|
volume:
|
|
|
|
backing: folder
|
|
|
|
partitions:
|
|
|
|
type: none
|
|
|
|
root:
|
|
|
|
filesystem: ext4
|
|
|
|
size: 1GiB
|
|
|
|
''',
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
def test_stable():
|
2016-06-04 11:35:59 +02:00
|
|
|
std_partials = ['base', 'stable64']
|
|
|
|
custom_partials = [partials['docker']]
|
|
|
|
manifest_data = merge_manifest_data(std_partials, custom_partials)
|
|
|
|
with boot_manifest(manifest_data) as instance:
|
2018-04-09 22:13:21 -07:00
|
|
|
print('\n'.join(instance.run(['echo', 'test']))) # pylint: disable=print-statement
|