#NEWLINE# def test_cannot_add_user_to_group_when_one_doesnt_exist( self ) : #NEWLINE# #INDENT# res = self . post ( self . url , { #NEWLINE# #INDENT# 'group' : 'reviewer' , #NEWLINE# #UNINDENT# } ) #NEWLINE# assert ( res . status_code == 422 ) , res . content #NEWLINE# assert ( res . data [ 'errors' ] == { #NEWLINE# #INDENT# 'group' : [ 'Could not find a permissions group with the exact rules needed.' ] , #NEWLINE# #UNINDENT# } )