import pkg_resources


def load_plugins_by_namespace(namespace):
    """Loads audit steps defined in `setup.py` under a given namespace.

    Args:
        namespace (str): namespace under which to look for plugins.
    Returns:
        Loaded plugin objects (list).
    """
    return [e.load() for e in pkg_resources.iter_entry_points(namespace)]