diff options
author | Pavel Zuna <pzuna@redhat.com> | 2010-10-05 15:37:37 -0400 |
---|---|---|
committer | Rob Crittenden <rcritten@redhat.com> | 2010-10-06 09:20:44 -0400 |
commit | 6606b2a9c5599446b66af347c92f3878f24c47d6 (patch) | |
tree | 8c5bfe0c851beacb6410c720a4c9646a80f7d9e5 | |
parent | 9832780414703e49671b380c7e3042581ecfe70c (diff) | |
download | freeipa-6606b2a9c5599446b66af347c92f3878f24c47d6.tar.gz freeipa-6606b2a9c5599446b66af347c92f3878f24c47d6.tar.xz freeipa-6606b2a9c5599446b66af347c92f3878f24c47d6.zip |
Rename user-lock and user-unlock to user-enable user-disable.
Ticket #165
-rw-r--r-- | ipalib/plugins/user.py | 24 | ||||
-rw-r--r-- | tests/test_xmlrpc/test_user_plugin.py | 12 |
2 files changed, 18 insertions, 18 deletions
diff --git a/ipalib/plugins/user.py b/ipalib/plugins/user.py index 074655344..a6e6b5d2c 100644 --- a/ipalib/plugins/user.py +++ b/ipalib/plugins/user.py @@ -37,11 +37,11 @@ EXAMPLES: Find all users with "Tim" as the first name: ipa user-find --first=Tim - Lock a user account: - ipa user-lock tuser1 + Disable a user account: + ipa user-disable tuser1 - Unlock a user account: - ipa user-unlock tuser1 + Enable a user account: + ipa user-enable tuser1 Delete a user: ipa user-del tuser1 @@ -274,13 +274,13 @@ class user_show(LDAPRetrieve): api.register(user_show) -class user_lock(LDAPQuery): +class user_disable(LDAPQuery): """ - Lock a user account. + Disable user account. """ has_output = output.standard_value - msg_summary = _('Locked user "%(value)s"') + msg_summary = _('Disabled user account "%(value)s"') def execute(self, *keys, **options): ldap = self.obj.backend @@ -297,16 +297,16 @@ class user_lock(LDAPQuery): value=keys[0], ) -api.register(user_lock) +api.register(user_disable) -class user_unlock(LDAPQuery): +class user_enable(LDAPQuery): """ - Unlock a user account. + Enable user account. """ has_output = output.standard_value - msg_summary = _('Unlocked user "%(value)s"') + msg_summary = _('Enabled user account "%(value)s"') def execute(self, *keys, **options): ldap = self.obj.backend @@ -323,4 +323,4 @@ class user_unlock(LDAPQuery): value=keys[0], ) -api.register(user_unlock) +api.register(user_enable) diff --git a/tests/test_xmlrpc/test_user_plugin.py b/tests/test_xmlrpc/test_user_plugin.py index 1cbccbbc4..c6770b700 100644 --- a/tests/test_xmlrpc/test_user_plugin.py +++ b/tests/test_xmlrpc/test_user_plugin.py @@ -234,27 +234,27 @@ class test_user(Declarative): dict( - desc='Lock %r' % user1, + desc='Disable %r' % user1, command=( - 'user_lock', [user1], {} + 'user_disable', [user1], {} ), expected=dict( result=True, value=user1, - summary=u'Locked user "tuser1"', + summary=u'Disabled user account "tuser1"', ), ), dict( - desc='Unlock %r' % user1, + desc='Enable %r' % user1, command=( - 'user_unlock', [user1], {} + 'user_enable', [user1], {} ), expected=dict( result=True, value=user1, - summary=u'Unlocked user "tuser1"', + summary=u'Enabled user account "tuser1"', ), ), |