From da0918e71e82c407e1dc7f5cb80f33cad93263af Mon Sep 17 00:00:00 2001 From: "Chris St. Pierre" Date: Tue, 13 Aug 2013 09:31:49 -0400 Subject: testsuite: fixed unit tests for new SSLCA stuff --- src/lib/Bcfg2/Server/Plugins/Cfg/__init__.py | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) (limited to 'src/lib/Bcfg2/Server/Plugins/Cfg') diff --git a/src/lib/Bcfg2/Server/Plugins/Cfg/__init__.py b/src/lib/Bcfg2/Server/Plugins/Cfg/__init__.py index 21dc35e5a..eea0a3456 100644 --- a/src/lib/Bcfg2/Server/Plugins/Cfg/__init__.py +++ b/src/lib/Bcfg2/Server/Plugins/Cfg/__init__.py @@ -10,7 +10,7 @@ import Bcfg2.Options import Bcfg2.Server.Plugin from Bcfg2.Server.Plugin import PluginExecutionError # pylint: disable=W0622 -from Bcfg2.Compat import u_str, unicode, b64encode, any +from Bcfg2.Compat import u_str, unicode, b64encode, any, walk_packages # pylint: enable=W0622 try: @@ -19,9 +19,12 @@ try: except ImportError: HAS_CRYPTO = False +_handlers = [m[1] # pylint: disable=C0103 + for m in walk_packages(path=__path__)] _CFG = None + def get_cfg(): """ Get the :class:`Bcfg2.Server.Plugins.Cfg.Cfg` plugin object created by the Bcfg2 core. This is provided so that the handler @@ -888,13 +891,7 @@ class Cfg(Bcfg2.Server.Plugin.GroupSpool, cf=("cfg", "handlers"), dest="cfg_handlers", help="Cfg handlers to load", type=Bcfg2.Options.Types.comma_list, action=CfgHandlerAction, - default=['CfgAuthorizedKeysGenerator', 'CfgEncryptedGenerator', - 'CfgCheetahGenerator', 'CfgEncryptedCheetahGenerator', - 'CfgGenshiGenerator', 'CfgEncryptedGenshiGenerator', - 'CfgExternalCommandVerifier', 'CfgInfoXML', - 'CfgPlaintextGenerator', - 'CfgPrivateKeyCreator', 'CfgPublicKeyCreator', - 'CfgSSLCACertCreator', 'CfgSSLCAKeyCreator'])] + default=_handlers)] def __init__(self, core, datastore): global _CFG # pylint: disable=W0603 -- cgit v1.2.3-1-g7c22