#NEWLINE# def test_validation_error( self ) : #NEWLINE# #INDENT# ( left , right ) = make_a_nice_tree ( self . root_node , self . widgy_site ) #NEWLINE# obj = RawTextWidget . objects . all ( ) [ 0 ] #NEWLINE# url = obj . get_api_url ( self . widgy_site ) #NEWLINE# data = obj . to_json ( self . widgy_site ) #NEWLINE# data [ 'attributes' ] [ 'text' ] = '' #NEWLINE# resp = self . put ( url , data ) #NEWLINE# self . assertEqual ( resp . status_code , 409 ) #NEWLINE# self . assertIn ( 'text' , decode_json_request ( resp ) )