#NEWLINE# @ classmethod #NEWLINE# def setup_class( cls ) : #NEWLINE# #INDENT# cls . default_config_name = 'fetcher_config.yml' #NEWLINE# cls . json_config = { #NEWLINE# #INDENT# 'openstack_env' : True , #NEWLINE# 'kerberos_used' : True , #NEWLINE# 'machines' : { #NEWLINE# #INDENT# 'cdh-launcher' : { #NEWLINE# #INDENT# 'hostname' : '10.10.10.10' , #NEWLINE# 'hostport' : 22 , #NEWLINE# 'username' : 'centos' , #NEWLINE# 'key_filename' : 'key.pem' , #NEWLINE# 'key_password' : None , #NEWLINE# #UNINDENT# } , #NEWLINE# 'cdh-manager' : { #NEWLINE# #INDENT# 'ip' : '' , #NEWLINE# 'user' : 'test' , #NEWLINE# 'password' : 'test' , #NEWLINE# 'sshtunnel_required' : True , #NEWLINE# #UNINDENT# } , #NEWLINE# #UNINDENT# } , #NEWLINE# #UNINDENT# } #NEWLINE# cls . mock_config_content = yaml . dump ( cls . json_config ) #NEWLINE# with mock . patch ( '__builtin__.open' , mock . mock_open ( read_data = m . mock_config_content ) , create = True ) as m : #NEWLINE# #INDENT# cls . cdhUtilities = CdhConfExtractor ( )