#NEWLINE# def test_raise_exception_invalid_audience( self , jwt ) : #NEWLINE# #INDENT# payload = { #NEWLINE# #INDENT# 'some' : 'payload' , #NEWLINE# 'aud' : 'urn:someone-else' , #NEWLINE# #UNINDENT# } #NEWLINE# token = jwt . encode ( jwt , 'secret' ) #NEWLINE# with pytest . raises ( InvalidAudienceError ) : #NEWLINE# #INDENT# jwt . decode ( token , 'secret' , audience = 'urn-me' )