diff options
author | Yves Duhem <yves.duhem@mongodb.com> | 2018-02-27 11:29:41 -0500 |
---|---|---|
committer | Yves Duhem <yves.duhem@mongodb.com> | 2018-02-27 11:29:46 -0500 |
commit | 4a69dcaf78f29cf440ada961c7e59de6b5dde111 (patch) | |
tree | aceb8f015e234f940c94e67b5a756e1a7f8baab3 /buildscripts/resmokelib/testing/hooks/interface.py | |
parent | a77297dbe34d5cd838a4da55e9d83dc70c510bba (diff) | |
download | mongo-4a69dcaf78f29cf440ada961c7e59de6b5dde111.tar.gz |
SERVER-33476 Rename CustomBehavior to Hook
Diffstat (limited to 'buildscripts/resmokelib/testing/hooks/interface.py')
-rw-r--r-- | buildscripts/resmokelib/testing/hooks/interface.py | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/buildscripts/resmokelib/testing/hooks/interface.py b/buildscripts/resmokelib/testing/hooks/interface.py index cd5200764fc..75f222bbdd1 100644 --- a/buildscripts/resmokelib/testing/hooks/interface.py +++ b/buildscripts/resmokelib/testing/hooks/interface.py @@ -11,20 +11,20 @@ from ...utils import registry _HOOKS = {} -def make_custom_behavior(class_name, *args, **kwargs): +def make_hook(class_name, *args, **kwargs): """ - Factory function for creating CustomBehavior instances. + Factory function for creating Hook instances. """ if class_name not in _HOOKS: - raise ValueError("Unknown custom behavior class '%s'" % (class_name)) + raise ValueError("Unknown hook class '%s'" % class_name) return _HOOKS[class_name](*args, **kwargs) -class CustomBehavior(object): +class Hook(object): """ - The common interface all CustomBehaviors will inherit from. + The common interface all Hooks will inherit from. """ __metaclass__ = registry.make_registry_metaclass(_HOOKS) @@ -34,7 +34,7 @@ class CustomBehavior(object): @staticmethod def start_dynamic_test(hook_test_case, test_report): """ - If a CustomBehavior wants to add a test case that will show up + If a Hook wants to add a test case that will show up in the test report, it should use this method to add it to the report, since we will need to count it as a dynamic test to get the stats in the summary information right. @@ -43,7 +43,7 @@ class CustomBehavior(object): def __init__(self, hook_logger, fixture, description): """ - Initializes the CustomBehavior with the specified fixture. + Initializes the Hook with the specified fixture. """ if not isinstance(hook_logger, loggers.HookLogger): |