#NEWLINE# def test_update_method( self ) : #NEWLINE# #INDENT# object_data = { #NEWLINE# #INDENT# 'id' : 1 , #NEWLINE# 'action_group' : 'test_group' , #NEWLINE# 'action_name' : 'test_action' , #NEWLINE# 'action_type' : consts . ACTION_TYPES . nailgun_task , #NEWLINE# 'additional_info' : { #NEWLINE# #INDENT# 'already_present_data' : None , #NEWLINE# #UNINDENT# } , #NEWLINE# 'is_sent' : False , #NEWLINE# 'cluster_id' : 1 , #NEWLINE# 'task_uuid' : str ( uuid . uuid4 ( ) ) , #NEWLINE# #UNINDENT# } #NEWLINE# al = self . _create_log_entry ( object_data ) #NEWLINE# update_kwargs = { #NEWLINE# #INDENT# 'additional_info' : { #NEWLINE# #INDENT# 'new_data' : [ ] , #NEWLINE# #UNINDENT# } , #NEWLINE# #UNINDENT# } #NEWLINE# al = objects . ActionLog . update ( al , update_kwargs ) #NEWLINE# self . assertIn ( 'new_data' , six . iterkeys ( al . additional_info ) ) #NEWLINE# self . assertIn ( 'already_present_data' , six . iterkeys ( al . additional_info ) ) #NEWLINE# self . db . rollback ( )