mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2025-02-25 18:55:28 -06:00
121: Renamed API.__call__() method to API.finalize()
This commit is contained in:
parent
f767543fe7
commit
b72cfa5dcc
@ -485,7 +485,7 @@ class API(ReadOnly):
|
|||||||
self.register = Registrar(*allowed)
|
self.register = Registrar(*allowed)
|
||||||
self.__lock__()
|
self.__lock__()
|
||||||
|
|
||||||
def __call__(self):
|
def finalize(self):
|
||||||
"""
|
"""
|
||||||
Finalize the registration, instantiate the plugins.
|
Finalize the registration, instantiate the plugins.
|
||||||
"""
|
"""
|
||||||
|
@ -28,4 +28,4 @@ unnecessary side effects (needed for unit tests, among other things).
|
|||||||
from run import api
|
from run import api
|
||||||
import plugins
|
import plugins
|
||||||
|
|
||||||
api()
|
api.finalize()
|
||||||
|
@ -601,7 +601,7 @@ def test_API():
|
|||||||
r(base1_plugin2)
|
r(base1_plugin2)
|
||||||
|
|
||||||
# Test API instance:
|
# Test API instance:
|
||||||
api() # Calling instance performs finalization
|
api.finalize()
|
||||||
|
|
||||||
def get_base(b):
|
def get_base(b):
|
||||||
return 'base%d' % b
|
return 'base%d' % b
|
||||||
|
@ -374,4 +374,4 @@ def test_PublicAPI():
|
|||||||
pass
|
pass
|
||||||
api.register(cmd2)
|
api.register(cmd2)
|
||||||
|
|
||||||
api()
|
api.finalize()
|
||||||
|
Loading…
Reference in New Issue
Block a user