#NEWLINE# def test_logs_exceptions_during_rendering_with_debug_disabled( self ) : #NEWLINE# #INDENT# template = self . engine . from_string ( '{% include "child" %}' ) #NEWLINE# template . name = 'template_name' #NEWLINE# self . assertEqual ( template . render ( self . ctx ) , '' ) #NEWLINE# self . assertEqual ( self . test_handler . log_record . getMessage ( ) , "Exception raised while rendering {% include %} for template 'template_name'. Empty string rendered instead." ) #NEWLINE# self . assertIsNotNone ( template . test_handler . log_record . exc_info ) #NEWLINE# self . assertEqual ( self . test_handler . log_record . levelno , logging . WARN )