#NEWLINE# def generate_test_vm_image_data( self , node ) : #NEWLINE# #INDENT# attrs = node . cluster . attributes #NEWLINE# image_data = super ( DeploymentHASerializer61 , self ) . generate_test_vm_image_data ( node ) #NEWLINE# images_data = { #NEWLINE# #INDENT# #NEWLINE# #UNINDENT# } #NEWLINE# images_data [ 'test_vm_image' ] = [ ] #NEWLINE# if ( attrs . get ( 'editable' , { #NEWLINE# #INDENT# #NEWLINE# #UNINDENT# } ) . get ( 'common' , { #NEWLINE# #INDENT# #NEWLINE# #UNINDENT# } ) . get ( 'use_vcenter' , { #NEWLINE# #INDENT# #NEWLINE# #UNINDENT# } ) . get ( 'value' ) is True ) : #NEWLINE# #INDENT# image_vmdk_data = deepcopy ( image_data [ 'test_vm_image' ] ) #NEWLINE# img_path = image_vmdk_data [ 'img_path' ] . replace ( 'x86_64-disk.img' , 'i386-disk.vmdk' ) #NEWLINE# image_vmdk_data . update ( { #NEWLINE# #INDENT# 'img_name' : 'TestVM-VMDK' , #NEWLINE# 'disk_format' : 'vmdk' , #NEWLINE# 'img_path' : img_path , #NEWLINE# #UNINDENT# } ) #NEWLINE# properties_data = { #NEWLINE# #INDENT# 'vmware_disktype' : 'sparse' , #NEWLINE# 'vmware_adaptertype' : 'lsiLogic' , #NEWLINE# 'hypervisor_type' : 'vmware' , #NEWLINE# #UNINDENT# } #NEWLINE# glance_properties = self . generate_properties_arguments ( properties_data ) #NEWLINE# image_vmdk_data [ 'glance_properties' ] = glance_properties #NEWLINE# image_vmdk_data [ 'properties' ] = properties_data #NEWLINE# images_data [ 'test_vm_image' ] . append ( image_vmdk_data ) #NEWLINE# images_data [ 'test_vm_image' ] . append ( image_data [ 'test_vm_image' ] ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# images_data = image_data #NEWLINE# #UNINDENT# return images_data