#NEWLINE# def test_owner_edits_org( self ) : #NEWLINE# #INDENT# user = self . owner . user #NEWLINE# request = request_factory_login ( self . factory , user ) #NEWLINE# form = OrganizationForm ( request , instance = self . org , data = { #NEWLINE# #INDENT# 'name' : self . org . name , #NEWLINE# 'slug' : self . org . slug , #NEWLINE# 'owner' : self . owner . id , #NEWLINE# #UNINDENT# } ) #NEWLINE# self . assertTrue ( form . is_valid ( ) ) #NEWLINE# form = OrganizationForm ( request , instance = self . org , data = { #NEWLINE# #INDENT# 'name' : self . org . name , #NEWLINE# 'slug' : self . org . slug , #NEWLINE# 'owner' : self . admin . id , #NEWLINE# #UNINDENT# } ) #NEWLINE# self . assertTrue ( form . is_valid ( ) ) #NEWLINE# form . save ( ) #NEWLINE# self . assertEqual ( self . org . owner . organization_user , self . admin )