def test_update_listener(self):
     """lbaas-listener-update myid --name newname."""
     resource = 'listener'
     cmd_resource = 'lbaas_listener'
     cmd = listener.UpdateListener(test_cli20.MyApp(sys.stdout), None)
     self._test_update_resource(resource, cmd, 'myid',
                                ['myid', '--name', 'newname'],
                                {'name': 'newname', },
                                cmd_resource=cmd_resource)
 def _test_update_listener(self, args, expected_values):
     resource = 'listener'
     cmd_resource = 'lbaas_listener'
     my_id = 'myid'
     args.insert(0, my_id)
     cmd = listener.UpdateListener(test_cli20.MyApp(sys.stdout), None)
     self._test_update_resource(resource,
                                cmd,
                                my_id,
                                args,
                                expected_values,
                                cmd_resource=cmd_resource)