Intercepts call to generate new mocks and raises instead

def _get_child_mock(mock, **kw):
    """Intercepts call to generate new mocks and raises instead"""
    attribute = "." + kw["name"] if "name" in kw else "()"
    mock_name = _extract_mock_name(mock) + attribute
    raise AttributeError(mock_name)