Exemple #1
0
def create_initrd_kernel(missing=False):
    """
    Creates initrd and kernel test file.
    """
    if not os.path.exists('/tmp/test_tunir/'):
        os.mkdir('/tmp/test_tunir/')
    seed_path = '/tmp/test_tunir/seed.img'
    system('touch /tmp/test_tunir/test.qcow2')
    if not missing:
        system('touch /tmp/test_tunir/test-vmlinuz')
        system('touch /tmp/test_tunir/test-initramfs')
    system('touch %s' % seed_path)
Exemple #2
0
 def tearDown(self):
     system('rm -rf /tmp/test_tunir')