#NEWLINE# def test_image_properties_filter_pv_mode_compat( self ) : #NEWLINE# #INDENT# img_props = objects . ImageMeta ( properties = objects . ImageMetaProps ( hw_vm_mode = 'pv' ) ) #NEWLINE# hypervisor_version = versionutils . convert_version_to_int ( '6.0.0' ) #NEWLINE# spec_obj = objects . RequestSpec ( image = img_props ) #NEWLINE# capabilities = { #NEWLINE# #INDENT# 'supported_instances' : [ ( arch . X86_64 , hv_type . XEN , vm_mode . XEN ) ] , #NEWLINE# 'hypervisor_version' : host , #NEWLINE# #UNINDENT# } #NEWLINE# host = fakes . FakeHostState ( 'host1' , 'node1' , capabilities ) #NEWLINE# self . assertTrue ( self . filt_cls . host_passes ( host , spec_obj ) )