#NEWLINE# def test_load_marathon_service_config_bails_with_no_config( self ) : #NEWLINE# #INDENT# fake_name = 'jazz' #NEWLINE# fake_instance = 'solo' #NEWLINE# fake_cluster = 'amnesia' #NEWLINE# fake_dir = '/nail/home/sanfran' #NEWLINE# with contextlib . nested ( mock . patch ( 'paasta_tools.marathon_tools.load_deployments_json' , autospec = True ) , mock . patch ( 'service_configuration_lib.read_service_configuration' , autospec = True ) , mock . patch ( 'service_configuration_lib.read_extra_service_information' , autospec = True ) ) as ( mock_load_deployments_json , mock_read_service_configuration , mock_read_extra_service_information ) : #NEWLINE# #INDENT# mock_read_extra_service_information . return_value = { #NEWLINE# #INDENT# #NEWLINE# #UNINDENT# } #NEWLINE# with raises ( marathon_tools . NoConfigurationForServiceError ) : #NEWLINE# #INDENT# marathon_tools . load_marathon_service_config ( fake_dir , fake_instance , fake_cluster , soa_dir = fake_dir )