dns, passwd: fix outputs of dns_resolve and passwd commands

Use proper output type for the `value` output of the commands.

https://fedorahosted.org/freeipa/ticket/4739

Reviewed-By: David Kupka <dkupka@redhat.com>
This commit is contained in:
Jan Cholasta 2016-06-15 08:02:30 +02:00
parent 365d973763
commit 448af06234
4 changed files with 10 additions and 4 deletions

View File

@ -1053,7 +1053,7 @@ arg: Str('hostname')
option: Str('version?')
output: Output('result', type=[<type 'bool'>])
output: Output('summary', type=[<type 'unicode'>, <type 'NoneType'>])
output: PrimaryKey('value')
output: Output('value', type=[<type 'unicode'>])
command: dnsconfig_mod
args: 0,11,3
option: Str('addattr*', cli_name='addattr')
@ -3317,7 +3317,7 @@ option: Password('otp?', confirm=False)
option: Str('version?')
output: Output('result', type=[<type 'bool'>])
output: Output('summary', type=[<type 'unicode'>, <type 'NoneType'>])
output: PrimaryKey('value')
output: Output('value', type=[<type 'unicode'>])
command: permission_add
args: 1,21,3
arg: Str('cn', cli_name='name')

View File

@ -211,3 +211,9 @@ standard_boolean = (
)
standard_value = standard_boolean
simple_value = (
summary,
Output('result', bool, _('True means the operation was successful')),
Output('value', unicode, flags=['no_display']),
)

View File

@ -3965,7 +3965,7 @@ class dns_resolve(Command):
NO_CLI = True
has_output = output.standard_value
has_output = output.simple_value
msg_summary = _('Found \'%(value)s\'')
takes_args = (

View File

@ -97,7 +97,7 @@ class passwd(Command):
),
)
has_output = output.standard_value
has_output = output.simple_value
msg_summary = _('Changed password for "%(value)s"')
def execute(self, principal, password, current_password, **options):