#NEWLINE# def test_list_policy_rules( self ) : #NEWLINE# #INDENT# policy_name = 'classification' #NEWLINE# rule_id = 'e531f2b3-3d97-42c0-b3b5-b7b6ab532018' #NEWLINE# arglist = [ policy_name ] #NEWLINE# verifylist = [ ( 'policy_name' , policy_name ) ] #NEWLINE# response = { #NEWLINE# #INDENT# 'results' : [ { #NEWLINE# #INDENT# 'comment' : 'None' , #NEWLINE# 'id' : rule_id , #NEWLINE# 'rule' : 'security_group(port, security_group_name)' , #NEWLINE# #UNINDENT# } ] , #NEWLINE# #UNINDENT# } #NEWLINE# lister = mock . Mock ( return_value = response ) #NEWLINE# self . app . client_manager . congressclient . list_policy_rules = lister #NEWLINE# cmd = policy . ListPolicyRules ( self . app , self . namespace ) #NEWLINE# parsed_args = self . check_parser ( cmd , arglist , verifylist ) #NEWLINE# cmd . take_action ( parsed_args ) #NEWLINE# lister . assert_called_with ( policy_name )