#NEWLINE# def assertPermissionDenied( self , response ) : #NEWLINE# #INDENT# self . assertEqual ( response . data , { #NEWLINE# #INDENT# 'detail' : 'You do not have permission to perform this action.' , #NEWLINE# #UNINDENT# } ) #NEWLINE# self . assertEqual ( response . status_code , status . HTTP_403_FORBIDDEN )