#NEWLINE# def test_update( self , mock_reg ) : #NEWLINE# #INDENT# data = { #NEWLINE# #INDENT# 'user_id' : 'new_user_id' , #NEWLINE# 'image_id' : 'new_image_id' , #NEWLINE# 'heat_stack_id' : 'new_stack_id' , #NEWLINE# #UNINDENT# } #NEWLINE# handler = infra . InfrastructureStackHandler ( self . ctx ) #NEWLINE# handler . update ( 'test_id' , data ) #NEWLINE# mock_reg . InfrastructureStack . update_and_save . assert_called_once_with ( mock_reg . ctx , 'test_id' , data )