Partially revert back change. Del shouldn't provide default options.

It can provide custom ones though, if defined with takes_params() in the class.
This commit is contained in:
Rob Crittenden committed 2008-11-03 13:14:46 -05:00
1 parent a9e8bda0cf
commit f18c84444d
2 files changed
+2 -5

No files matched your search

-2
View File
@@ -47,8 +47,6 @@ class Del(frontend.Method):
yield self.obj.primary_key
def get_options(self):
for param in self.obj.params_minus_pk():
yield param
for option in self.takes_options:
yield option
+2 -3
View File
@@ -130,9 +130,8 @@ class test_Del(CrudChecker):
Test the `ipalib.crud.Del.get_options` method.
"""
api = self.get_api()
assert list(api.Method.user_verb.options) == \
['givenname', 'sn', 'initials']
assert len(api.Method.user_verb.options) == 3
assert list(api.Method.user_verb.options) == []
assert len(api.Method.user_verb.options) == 0
class test_Mod(CrudChecker):