diff options
author | Jason Gerard DeRose <jderose@redhat.com> | 2008-09-25 00:42:38 +0000 |
---|---|---|
committer | Jason Gerard DeRose <jderose@redhat.com> | 2008-09-25 00:42:38 +0000 |
commit | 4747563a802a08863d2195222b2f428e52af8502 (patch) | |
tree | b2e0ed40a5b62fe1a09a4d5b36fa8bc76d0687b0 /ipalib/tests | |
parent | 79b33ad3663b91ad7816cf55737faa28603fca70 (diff) | |
download | freeipa-4747563a802a08863d2195222b2f428e52af8502.tar.gz freeipa-4747563a802a08863d2195222b2f428e52af8502.tar.xz freeipa-4747563a802a08863d2195222b2f428e52af8502.zip |
356: Modified Method.get_options() to now pull from self.obj.params(); updated unit tests for Method.get_options()
Diffstat (limited to 'ipalib/tests')
-rw-r--r-- | ipalib/tests/test_frontend.py | 20 |
1 files changed, 3 insertions, 17 deletions
diff --git a/ipalib/tests/test_frontend.py b/ipalib/tests/test_frontend.py index ec7cccd61..e78aeeb26 100644 --- a/ipalib/tests/test_frontend.py +++ b/ipalib/tests/test_frontend.py @@ -910,24 +910,10 @@ class test_Method(ClassChecker): assert self.cls.implements(frontend.Command) def get_subcls(self): - class example_prop0(frontend.Property): - 'Prop zero' - class example_prop1(frontend.Property): - 'Prop one' class example_obj(object): - __prop = None - def __get_prop(self): - if self.__prop is None: - self.__prop = plugable.NameSpace([ - plugable.PluginProxy( - frontend.Property, example_prop0(), 'attr_name' - ), - plugable.PluginProxy( - frontend.Property, example_prop1(), 'attr_name' - ), - ]) - return self.__prop - properties = property(__get_prop) + params = plugable.NameSpace( + frontend.create_param(n) for n in ('prop0', 'prop1') + ) type_ = ipa_types.Unicode() class noun_verb(self.cls): takes_options= ( |