#NEWLINE# def test_template_filter_with_name_and_template( ) : #NEWLINE# #INDENT# app = flask . Flask ( __name__ ) #NEWLINE# @ app . template_filter ( 'super_reverse' ) #NEWLINE# def my_reverse( s ) : #NEWLINE# #INDENT# return s [ : : ( - 1 ) ] #NEWLINE# #UNINDENT# @ app . route ( '/' ) #NEWLINE# def index( ) : #NEWLINE# #INDENT# return flask . render_template ( 'template_filter.html' , value = 'abcd' ) #NEWLINE# #UNINDENT# rv = app . test_client ( ) . get ( '/' ) #NEWLINE# assert ( rv . data == b'dcba' )