#NEWLINE# def test_add_members_to_org( self ) : #NEWLINE# #INDENT# self . _org_create ( ) #NEWLINE# view = OrganizationProfileViewSet . as_view ( { #NEWLINE# #INDENT# 'post' : 'members' , #NEWLINE# #UNINDENT# } ) #NEWLINE# User . objects . create ( username = 'aboy' ) #NEWLINE# data = { #NEWLINE# #INDENT# 'username' : 'aboy' , #NEWLINE# #UNINDENT# } #NEWLINE# request = self . factory . post ( '/' , data = json . dumps ( data ) , content_type = 'application/json' , ** self . extra ) #NEWLINE# response = view ( request , user = 'denoinc' ) #NEWLINE# self . assertEqual ( response . status_code , 201 ) #NEWLINE# self . assertEqual ( view . data , [ 'denoinc' , 'aboy' ] )