#NEWLINE# def test_view_based_feature_flag_returns_new_code_if_flag_is_on( self ) : #NEWLINE# #INDENT# with self . app . test_request_context ( '/' ) : #NEWLINE# #INDENT# url = url_for ( 'view_based_feature_flag' ) #NEWLINE# app . config [ FLAG_CONFIG ] [ FEATURE_NAME ] = True #NEWLINE# response = self . test_client . get ( url ) #NEWLINE# assert ( response . status_code == 200 ) , ( 'Unexpected status code %s' % self . status_code ) #NEWLINE# assert ( FEATURE_IS_ON in response . data . decode ( 'utf-8' ) )