def cleanup(): # pylint: disable=unused-variable for group in list(gossip.get_groups()): if group.name == 'slash': continue group.undefine() for hook in gossip.get_all_hooks(): if hook.group.name != 'slash': hook.undefine() else: hook.unregister_all()
def cleanup(): for group in list(gossip.get_groups()): if group.name == 'slash': continue group.undefine() for hook in gossip.get_all_hooks(): if hook.group.name != 'slash': hook.undefine() else: hook.unregister_all()
def test_global_group_reset_delets_all_group(registered_hooks): assert gossip.get_groups() gossip.get_global_group().reset() assert not gossip.get_groups() assert all(not r.works() for r in registered_hooks) assert not gossip.get_global_group().get_subgroups()