#NEWLINE# @ is_private ( ) #NEWLINE# def test_feedbacks( self ) : #NEWLINE# #INDENT# gpm [ 'Feedback__limit_size' ] = 1 #NEWLINE# feedback_size = ( ( 10 * 1024 ) * 1023 ) #NEWLINE# FeedbackFactory . create_batch ( 200 , screenshot_size = feedback_size , system_logs_size = 0 , attached_file_size = 0 , blackbox_size = 0 ) #NEWLINE# self . assertEqual ( Feedback . objects . all ( ) . count ( ) , 200 ) #NEWLINE# del_count = 98 #NEWLINE# deleted = list ( Feedback . objects . values_list ( 'id' , 'created' ) ) #NEWLINE# deleted = map ( ( lambda x : dict ( id = x [ 0 ] , element_created = x [ 1 ] . strftime ( '%d. %B %Y %I:%M%p' ) ) ) , deleted ) [ : del_count ] #NEWLINE# result = delete_size_is_exceeded ( 'feedback' , 'Feedback' ) #NEWLINE# self . assertDictEqual ( result , dict ( count = del_count , size = ( del_count * feedback_size ) , elements = deleted ) ) #NEWLINE# self . assertEqual ( Feedback . objects . all ( ) . count ( ) , 102 )