#NEWLINE# def test_document_multiple_document_type_change_view_with_permission( self ) : #NEWLINE# #INDENT# self . login ( username = TEST_USER_USERNAME , password = TEST_USER_PASSWORD ) #NEWLINE# self . assertEqual ( Document . objects . first ( ) . document_type , self . document_type ) #NEWLINE# document_type = DocumentType . objects . create ( label = TEST_DOCUMENT_TYPE_2_LABEL ) #NEWLINE# self . role . permissions . add ( permission_document_properties_edit . stored_permission ) #NEWLINE# response = self . post ( 'documents:document_multiple_document_type_edit' , data = { #NEWLINE# #INDENT# 'id_list' : document_type . document . pk , #NEWLINE# 'document_type' : document_type . pk , #NEWLINE# #UNINDENT# } , follow = True ) #NEWLINE# self . assertEqual ( response . status_code , 200 ) #NEWLINE# self . assertEqual ( Document . objects . first ( ) . document_type , document_type )