def createVHD(self, hdImage, filebase): diskType = self.getBuildData('vhdDiskType') if diskType == 'fixed': vhd.makeFlat(hdImage) os.rename(hdImage, filebase + '.vhd') elif diskType == 'difference': vhd.makeDynamic(hdImage, filebase + '-base.vhd') os.chmod(filebase + '-base.vhd', 0400) vhd.makeDifference(filebase + '-base.vhd', filebase + '.vhd', self.basefilename + '-base.vhd') else: vhd.makeDynamic(hdImage, filebase + '.vhd')
def testFlat(self): vhd.makeFlat(self.fn) self.validateVHD(self.fn)