diff --git a/tests/test_plugin.py b/tests/test_plugin.py index 9ae65869d93c0d02c63942197b402a3c1831eb8a..0a5ab619572b60a513dae77aa7ae8eda4e995fdd 100644 --- a/tests/test_plugin.py +++ b/tests/test_plugin.py @@ -112,6 +112,15 @@ def test_registry_unknown_group_name(): with pytest.raises(ValueError): next(HOOK_REGISTRY.group_by_directive('UnKnownTestGroup')) +def test_registry_load_included_hooks(): + registry = plugin.HookRegistry() + assert not list(registry.group_by_directive()) + registry.load_included_hooks() + actual = {hook.__name__ for key, hook in registry.group_by_directive() if key == 'Transaction'} + assert len(actual) >= 5 + assert 'MetaProject' in actual + assert 'MetaRTLinks' in actual + def test_run_with_multiple_hooks(easy_entries, config_map): out_entries, errors = plugin.run(easy_entries, config_map, '', HOOK_REGISTRY) assert len(out_entries) == 2