summaryrefslogtreecommitdiffstats
path: root/roles/openshift_health_checker/action_plugins
diff options
context:
space:
mode:
authorOpenShift Bot <eparis+openshiftbot@redhat.com>2017-03-28 07:54:59 -0500
committerGitHub <noreply@github.com>2017-03-28 07:54:59 -0500
commite9a4e751bc28f43583087ce6502a36c5d83cf30d (patch)
tree9a5f816d8dd5c40d6b682fe514ce41fd4435d4cb /roles/openshift_health_checker/action_plugins
parent0d38f04595fc2098cf8304faf20e15e62f43955c (diff)
parentd6cf72a4f488d8c275bfbaf27620ff716da1ae5d (diff)
downloadopenshift-e9a4e751bc28f43583087ce6502a36c5d83cf30d.tar.gz
openshift-e9a4e751bc28f43583087ce6502a36c5d83cf30d.tar.bz2
openshift-e9a4e751bc28f43583087ce6502a36c5d83cf30d.tar.xz
openshift-e9a4e751bc28f43583087ce6502a36c5d83cf30d.zip
Merge pull request #3745 from rhcarvalho/checks-unit-tests
Merged by openshift-bot
Diffstat (limited to 'roles/openshift_health_checker/action_plugins')
-rw-r--r--roles/openshift_health_checker/action_plugins/openshift_health_check.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/roles/openshift_health_checker/action_plugins/openshift_health_check.py b/roles/openshift_health_checker/action_plugins/openshift_health_check.py
index 8b23533c8..cf0fe19f1 100644
--- a/roles/openshift_health_checker/action_plugins/openshift_health_check.py
+++ b/roles/openshift_health_checker/action_plugins/openshift_health_check.py
@@ -17,7 +17,7 @@ from ansible.plugins.action import ActionBase
# this callback plugin.
sys.path.insert(1, os.path.dirname(os.path.dirname(__file__)))
-from openshift_checks import OpenShiftCheck, OpenShiftCheckException # noqa: E402
+from openshift_checks import OpenShiftCheck, OpenShiftCheckException, load_checks # noqa: E402
class ActionModule(ActionBase):
@@ -78,6 +78,8 @@ class ActionModule(ActionBase):
return result
def load_known_checks(self):
+ load_checks()
+
known_checks = {}
known_check_classes = set(cls for cls in OpenShiftCheck.subclasses())
@@ -91,7 +93,7 @@ class ActionModule(ActionBase):
check_name,
cls.__module__, cls.__name__,
other_cls.__module__, other_cls.__name__))
- known_checks[check_name] = cls(module_executor=self._execute_module)
+ known_checks[check_name] = cls(execute_module=self._execute_module)
return known_checks