File diff fdb62dd1c641 → 0bf44ade7aee
tests/test_plugin.py
Show inline comments
...
 
@@ -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