diff options
author | Jan Cholasta <jcholast@redhat.com> | 2011-11-03 06:42:17 -0400 |
---|---|---|
committer | Rob Crittenden <rcritten@redhat.com> | 2011-11-22 00:52:24 -0500 |
commit | e7a6d1055574d2dd892f414dbe993ee5782ab488 (patch) | |
tree | a78fd289eef1743c3251c173a06526bea30e9bd9 /tests | |
parent | bce3cd945c66e8e8dc49382356348745eefe8c59 (diff) | |
download | freeipa-e7a6d1055574d2dd892f414dbe993ee5782ab488.tar.gz freeipa-e7a6d1055574d2dd892f414dbe993ee5782ab488.tar.xz freeipa-e7a6d1055574d2dd892f414dbe993ee5782ab488.zip |
Finalize plugin initialization on demand.
This patch changes the way plugins are initialized. Instead of
finalizing all the plugins at once, plugins are finalized only after
they are accessed (currently applies to Command, Object and
Attribute subclasses, only in CLI by default).
This change provides significant performance boost, as only the
plugins that are actually used are finalized.
ticket 1336
Diffstat (limited to 'tests')
-rw-r--r-- | tests/test_ipalib/test_frontend.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/tests/test_ipalib/test_frontend.py b/tests/test_ipalib/test_frontend.py index 0f6aecb3d..b717a43ad 100644 --- a/tests/test_ipalib/test_frontend.py +++ b/tests/test_ipalib/test_frontend.py @@ -942,7 +942,8 @@ class test_Object(ClassChecker): parameters.Str('four', primary_key=True), ) o = example3() - e = raises(ValueError, o.set_api, api) + o.set_api(api) + e = raises(ValueError, o.finalize) assert str(e) == \ 'example3 (Object) has multiple primary keys: one, two, four' |